@whatwg-node/fetch 0.8.8 → 0.9.0-alpha-20230515120642-be23d36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +25 -0
- package/dist/create-node-ponyfill.js +3 -16
- package/dist/deno-ponyfill.ts +0 -4
- package/dist/global-ponyfill.js +0 -2
- package/dist/index.d.ts +0 -4
- package/dist/node-ponyfill.js +0 -2
- package/package.json +3 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
1
|
# @whatwg-node/fetch
|
|
2
2
|
|
|
3
|
+
## 0.9.0-alpha-20230515120642-be23d36
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#535](https://github.com/ardatan/whatwg-node/pull/535)
|
|
8
|
+
[`ce067f3`](https://github.com/ardatan/whatwg-node/commit/ce067f3875430185c8177acb47c9b2d8d871f24e)
|
|
9
|
+
Thanks [@ardatan](https://github.com/ardatan)! - Drop Node 14 support
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#535](https://github.com/ardatan/whatwg-node/pull/535)
|
|
14
|
+
[`7e29490`](https://github.com/ardatan/whatwg-node/commit/7e294905f5683ed730f7975c59a0b829ea2c0e1f)
|
|
15
|
+
Thanks [@ardatan](https://github.com/ardatan)! - dependencies updates:
|
|
16
|
+
- Removed dependency
|
|
17
|
+
[`@peculiar/webcrypto@^1.4.0` ↗︎](https://www.npmjs.com/package/@peculiar/webcrypto/v/1.4.0)
|
|
18
|
+
(from `dependencies`)
|
|
19
|
+
- Removed dependency [`busboy@^1.6.0` ↗︎](https://www.npmjs.com/package/busboy/v/1.6.0) (from
|
|
20
|
+
`dependencies`)
|
|
21
|
+
- Removed dependency
|
|
22
|
+
[`web-streams-polyfill@^3.2.1` ↗︎](https://www.npmjs.com/package/web-streams-polyfill/v/3.2.1)
|
|
23
|
+
(from `dependencies`)
|
|
24
|
+
- Updated dependencies
|
|
25
|
+
[[`ce067f3`](https://github.com/ardatan/whatwg-node/commit/ce067f3875430185c8177acb47c9b2d8d871f24e)]:
|
|
26
|
+
- @whatwg-node/node-fetch@0.4.0-alpha-20230515120642-be23d36
|
|
27
|
+
|
|
3
28
|
## 0.8.8
|
|
4
29
|
|
|
5
30
|
### Patch Changes
|
|
@@ -19,7 +19,6 @@ module.exports = function createNodePonyfill(opts = {}) {
|
|
|
19
19
|
ponyfills.Response = newNodeFetch.Response;
|
|
20
20
|
ponyfills.Headers = newNodeFetch.Headers;
|
|
21
21
|
ponyfills.FormData = newNodeFetch.FormData;
|
|
22
|
-
ponyfills.AbortController = newNodeFetch.AbortController;
|
|
23
22
|
ponyfills.ReadableStream = newNodeFetch.ReadableStream;
|
|
24
23
|
|
|
25
24
|
ponyfills.URL = newNodeFetch.URL;
|
|
@@ -29,15 +28,9 @@ module.exports = function createNodePonyfill(opts = {}) {
|
|
|
29
28
|
ponyfills.TransformStream = globalThis.TransformStream;
|
|
30
29
|
|
|
31
30
|
if (!ponyfills.WritableStream) {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
ponyfills.TransformStream = streamsWeb.TransformStream;
|
|
36
|
-
} catch (e) {
|
|
37
|
-
const streamsWeb = require("web-streams-polyfill/ponyfill");
|
|
38
|
-
ponyfills.WritableStream = streamsWeb.WritableStream;
|
|
39
|
-
ponyfills.TransformStream = streamsWeb.TransformStream;
|
|
40
|
-
}
|
|
31
|
+
const streamsWeb = require("stream/web");
|
|
32
|
+
ponyfills.WritableStream = streamsWeb.WritableStream;
|
|
33
|
+
ponyfills.TransformStream = streamsWeb.TransformStream;
|
|
41
34
|
}
|
|
42
35
|
|
|
43
36
|
ponyfills.Blob = newNodeFetch.Blob;
|
|
@@ -46,7 +39,6 @@ module.exports = function createNodePonyfill(opts = {}) {
|
|
|
46
39
|
ponyfills.btoa = newNodeFetch.btoa;
|
|
47
40
|
ponyfills.TextEncoder = newNodeFetch.TextEncoder;
|
|
48
41
|
ponyfills.TextDecoder = newNodeFetch.TextDecoder;
|
|
49
|
-
ponyfills.AbortSignal = newNodeFetch.AbortSignal;
|
|
50
42
|
|
|
51
43
|
if (opts.formDataLimits) {
|
|
52
44
|
ponyfills.Body = class Body extends newNodeFetch.Body {
|
|
@@ -80,10 +72,5 @@ module.exports = function createNodePonyfill(opts = {}) {
|
|
|
80
72
|
ponyfills.crypto = cryptoModule.webcrypto;
|
|
81
73
|
}
|
|
82
74
|
|
|
83
|
-
if (!ponyfills.crypto) {
|
|
84
|
-
const cryptoPonyfill = require('@peculiar/webcrypto');
|
|
85
|
-
ponyfills.crypto = new cryptoPonyfill.Crypto();
|
|
86
|
-
}
|
|
87
|
-
|
|
88
75
|
return ponyfills;
|
|
89
76
|
}
|
package/dist/deno-ponyfill.ts
CHANGED
|
@@ -3,8 +3,6 @@ const Request = globalThis.Request;
|
|
|
3
3
|
const Response = globalThis.Response;
|
|
4
4
|
const Headers = globalThis.Headers;
|
|
5
5
|
const FormData = globalThis.FormData;
|
|
6
|
-
const AbortSignal = globalThis.AbortSignal;
|
|
7
|
-
const AbortController = globalThis.AbortController;
|
|
8
6
|
const ReadableStream = globalThis.ReadableStream;
|
|
9
7
|
const WritableStream = globalThis.WritableStream;
|
|
10
8
|
const TransformStream = globalThis.TransformStream;
|
|
@@ -25,8 +23,6 @@ export {
|
|
|
25
23
|
Request,
|
|
26
24
|
Response,
|
|
27
25
|
FormData,
|
|
28
|
-
AbortSignal,
|
|
29
|
-
AbortController,
|
|
30
26
|
ReadableStream,
|
|
31
27
|
WritableStream,
|
|
32
28
|
TransformStream,
|
package/dist/global-ponyfill.js
CHANGED
|
@@ -3,8 +3,6 @@ module.exports.Headers = globalThis.Headers;
|
|
|
3
3
|
module.exports.Request = globalThis.Request;
|
|
4
4
|
module.exports.Response = globalThis.Response;
|
|
5
5
|
module.exports.FormData = globalThis.FormData;
|
|
6
|
-
module.exports.AbortSignal = globalThis.AbortSignal;
|
|
7
|
-
module.exports.AbortController = globalThis.AbortController;
|
|
8
6
|
module.exports.ReadableStream = globalThis.ReadableStream;
|
|
9
7
|
module.exports.WritableStream = globalThis.WritableStream;
|
|
10
8
|
module.exports.TransformStream = globalThis.TransformStream;
|
package/dist/index.d.ts
CHANGED
|
@@ -12,8 +12,6 @@ declare module '@whatwg-node/fetch' {
|
|
|
12
12
|
};
|
|
13
13
|
export const Headers: typeof globalThis.Headers;
|
|
14
14
|
export const FormData: typeof globalThis.FormData;
|
|
15
|
-
export const AbortSignal: typeof globalThis.AbortSignal;
|
|
16
|
-
export const AbortController: typeof globalThis.AbortController;
|
|
17
15
|
export const ReadableStream: typeof globalThis.ReadableStream;
|
|
18
16
|
export const WritableStream: typeof globalThis.WritableStream;
|
|
19
17
|
export const TransformStream: typeof globalThis.TransformStream;
|
|
@@ -51,8 +49,6 @@ declare module '@whatwg-node/fetch' {
|
|
|
51
49
|
Response: typeof Response;
|
|
52
50
|
Headers: typeof Headers;
|
|
53
51
|
FormData: typeof FormData;
|
|
54
|
-
AbortSignal: typeof AbortSignal;
|
|
55
|
-
AbortController: typeof AbortController;
|
|
56
52
|
ReadableStream: typeof ReadableStream;
|
|
57
53
|
WritableStream: typeof WritableStream;
|
|
58
54
|
TransformStream: typeof TransformStream;
|
package/dist/node-ponyfill.js
CHANGED
|
@@ -7,8 +7,6 @@ module.exports.Headers = ponyfills.Headers;
|
|
|
7
7
|
module.exports.Request = ponyfills.Request;
|
|
8
8
|
module.exports.Response = ponyfills.Response;
|
|
9
9
|
module.exports.FormData = ponyfills.FormData;
|
|
10
|
-
module.exports.AbortSignal = ponyfills.AbortSignal;
|
|
11
|
-
module.exports.AbortController = ponyfills.AbortController;
|
|
12
10
|
module.exports.ReadableStream = ponyfills.ReadableStream;
|
|
13
11
|
module.exports.WritableStream = ponyfills.WritableStream;
|
|
14
12
|
module.exports.TransformStream = ponyfills.TransformStream;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@whatwg-node/fetch",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0-alpha-20230515120642-be23d36",
|
|
4
4
|
"description": "Cross Platform Smart Fetch Ponyfill",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -13,11 +13,8 @@
|
|
|
13
13
|
"browser": "dist/global-ponyfill.js",
|
|
14
14
|
"types": "dist/index.d.ts",
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@
|
|
17
|
-
"
|
|
18
|
-
"busboy": "^1.6.0",
|
|
19
|
-
"urlpattern-polyfill": "^8.0.0",
|
|
20
|
-
"web-streams-polyfill": "^3.2.1"
|
|
16
|
+
"@whatwg-node/node-fetch": "0.4.0-alpha-20230515120642-be23d36",
|
|
17
|
+
"urlpattern-polyfill": "^8.0.0"
|
|
21
18
|
},
|
|
22
19
|
"publishConfig": {
|
|
23
20
|
"access": "public"
|