Skip to content

Commit

Permalink
Merge branch 'visionmedia:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
yunnysunny authored Jan 20, 2022
2 parents 590b1ac + 6a101c2 commit 77b052a
Show file tree
Hide file tree
Showing 73 changed files with 7,906 additions and 5,540 deletions.
3 changes: 2 additions & 1 deletion .dist.babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@
}
}]
],
"sourceMaps": "inline"
"sourceMaps": "inline",
"comments": false
}
17 changes: 15 additions & 2 deletions .dist.eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,13 @@
"no-cond-assign": "off",
"no-redeclare": "off",
"node/no-exports-assign": "off",
"no-unsafe-finally": "off"
"no-unsafe-finally": "off",
"complexity": ["error", 10000],
"max-statements": "off",
"no-constant-condition": "off",
"no-control-regex": "off",
"no-fallthrough": "off",
"operator-linebreak": "off"
},
"globals": {
"regeneratorRuntime": "writable"
Expand All @@ -31,7 +37,14 @@
"Symbol",
"Object.getOwnPropertySymbols",
"Object.setPrototypeOf",
"Set"
"Set",
"Math.trunc",
"BigInt",
"Map",
"Reflect",
"WeakMap",
"WeakRef",
"WeakSet"
]
}
}
4 changes: 4 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx --no-install commitlint --edit $1
5 changes: 5 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

# enable next line when tests are fixed
# npm test
12 changes: 0 additions & 12 deletions .npmignore

This file was deleted.

3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
sudo: false
language: node_js
node_js:
- '16'
- '14'
- '12'
- '10'
after_success: npm run coverage

env:
Expand Down
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ test-node:
--throw-deprecation \
--reporter $(REPORTER) \
--timeout 5000 \
--exit \
$(NODETESTS)

test-node-http2:
Expand All @@ -22,6 +23,7 @@ test-node-http2:
--throw-deprecation \
--reporter $(REPORTER) \
--timeout 5000 \
--exit \
$(NODETESTS)

test-cov: lib-cov
Expand Down
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ Browser-ready versions of this module are available via [jsdelivr][], [unpkg][],
This is the solution for you if you're just using `<script>` tags everywhere!

```html
<script src="https://polyfill.io/v3/polyfill.min.js?features=Array.from,Promise,Symbol,Object.setPrototypeOf,Object.getOwnPropertySymbols,Set"></script>
<script src="https://polyfill.io/v3/polyfill.min.js?features=Array.from,Promise,Symbol,Object.setPrototypeOf,Object.getOwnPropertySymbols,Set,Math.trunc,BigInt,Map,Reflect,WeakMap,WeakRef,WeakSet,BigInt,Map,Reflect,WeakMap,WeakRef,WeakSet"></script>
<script src="https://cdn.jsdelivr.net/npm/superagent"></script>
<!-- if you wish to use unpkg.com instead: -->
<!-- <script src="https://unpkg.com/superagent"></script> -->
Expand Down Expand Up @@ -159,11 +159,11 @@ If you are using [browserify][], [webpack][], [rollup][], or another bundler, th
We recommend using <https://polyfill.io> (specifically with the bundle mentioned in [VanillaJS](#vanillajs) above):

```html
<script src="https://polyfill.io/v3/polyfill.min.js?features=Array.from,Promise,Symbol,Object.setPrototypeOf,Object.getOwnPropertySymbols,Set"></script>
<script src="https://polyfill.io/v3/polyfill.min.js?features=Array.from,Promise,Symbol,Object.setPrototypeOf,Object.getOwnPropertySymbols,Set,Math.trunc,BigInt,Map,Reflect,WeakMap,WeakRef,WeakSet"></script>
```

* IE 9-10 requires a polyfill for `Promise`, `Array.from`, `Symbol`, `Object.getOwnPropertySymbols`, and `Object.setPrototypeOf`
* IE 9 requires a polyfill for `window.FormData` (we recommend [formdata-polyfill][]) and `Set`
* IE 9 requires a polyfill for `window.FormData` (we recommend [formdata-polyfill][]), `Set`, `Math.trunc`, `BigInt`, `Map`, `Reflect`, `WeakMap`, `WeakRef`, and `WeakSet`


## Plugins
Expand Down Expand Up @@ -210,8 +210,12 @@ For SuperAgent extensions such as couchdb and oauth visit the [wiki](https://git

## Upgrading from previous versions

Please see [GitHub releases page](https://github.com/visionmedia/superagent/releases) for the current changelog.

Our breaking changes are mostly in rarely used functionality and from stricter error handling.

* [6.0 to 6.1](https://github.com/visionmedia/superagent/releases/tag/v6.1.0)
* Browser behaviour changed to match Node when serializing `application/x-www-form-urlencoded`, using `arrayFormat: 'indices'` semantics of `qs` library. (See: <https://www.npmjs.com/package/qs#stringifying>)
* [5.x to 6.x](https://github.com/visionmedia/superagent/releases/tag/v6.0.0):
* Retry behavior is still opt-in, however we now have a more fine-grained list of status codes and error codes that we retry against (see updated docs)
* A specific issue with Content-Type matching not being case-insensitive is fixed
Expand All @@ -229,7 +233,7 @@ Our breaking changes are mostly in rarely used functionality and from stricter e
* Ensure you're running Node 4 or later. We've dropped support for Node 0.x.
* Test code that calls `.send()` multiple times. Invalid calls to `.send()` will now throw instead of sending garbage.
* [1.x to 2.x](https://github.com/visionmedia/superagent/releases/tag/v2.0.0):
* If you use `.parse()` in the _browser_ version, rename it to `.serialize()`.
* If you use `.parse()` in the *browser* version, rename it to `.serialize()`.
* If you rely on `undefined` in query-string values being sent literally as the text "undefined", switch to checking for missing value instead. `?key=undefined` is now `?key` (without a value).
* If you use `.then()` in Internet Explorer, ensure that you have a polyfill that adds a global `Promise` object.
* 0.x to 1.x:
Expand All @@ -251,7 +255,7 @@ Our breaking changes are mostly in rarely used functionality and from stricter e
[MIT](LICENSE) © TJ Holowaychuk


##
##

[npm]: https://www.npmjs.com/

Expand Down
6 changes: 6 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Security Policy


## Reporting a Vulnerability

Please report security issues to `[email protected]`
Loading

0 comments on commit 77b052a

Please sign in to comment.