chore: remove node-fetch

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei
2023-05-02 19:12:41 +08:00
parent c85fe14488
commit 5211320619
4 changed files with 1 additions and 9 deletions

View File

@@ -1,5 +1,4 @@
import FormData from 'form-data'
import fetch from 'node-fetch'
import { fetchAdaptor } from '~/adaptors/fetch'
@@ -7,7 +6,6 @@ import { testAdaptor } from '../helpers/adaptor-test'
describe('test fetch adaptor', () => {
beforeAll(() => {
global.fetch = fetch as any
global.FormData = FormData as any
})
testAdaptor(fetchAdaptor)

View File

@@ -2,7 +2,6 @@
/* eslint-disable */
import AbortController from 'abort-controller'
import fetch, { Headers, Request, Response } from 'node-fetch'
const TEN_MEGABYTES = 1000 * 1000 * 10

View File

@@ -68,7 +68,6 @@
"express": "4.18.2",
"ky": "0.33.3",
"lodash": "4.17.21",
"node-fetch": "3.3.1",
"tsup": "6.7.0",
"umi-request": "1.4.0"
}

6
pnpm-lock.yaml generated
View File

@@ -415,9 +415,6 @@ importers:
lodash:
specifier: 4.17.21
version: 4.17.21
node-fetch:
specifier: 3.3.1
version: 3.3.1
tsup:
specifier: 6.7.0
version: 6.7.0(@swc/core@1.3.4)(ts-node@10.9.1)(typescript@5.0.4)
@@ -5847,7 +5844,6 @@ packages:
/graceful-fs@4.2.11:
resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==}
dev: true
/grapheme-splitter@1.0.4:
resolution: {integrity: sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==}
@@ -6413,7 +6409,7 @@ packages:
dependencies:
universalify: 2.0.0
optionalDependencies:
graceful-fs: 4.2.10
graceful-fs: 4.2.11
/jsonwebtoken@9.0.0:
resolution: {integrity: sha512-tuGfYXxkQGDPnLJ7SibiQgVgeDgfbPq2k2ICcbgqW8WxWLBAxKQM/ZCu/IT8SOSwmaYl4dpTFCW5xZv7YbbWUw==}