Skip to content

Commit 1fe8b13

Browse files
committed
fix build and test
1 parent c7eb38e commit 1fe8b13

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/api/index.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
import fetch from "node-fetch";
1+
// import fetch from "node-fetch";
2+
// mod.cjs
3+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
4+
// @ts-ignore
5+
const fetch = (...args) => import("node-fetch").then(({ default: fetch }) => fetch(...args));
26
import * as httpModule from "http";
37
import * as httpsModule from "https";
48
import * as url from "url";

tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"extends": "./tsconfig.base.json",
33
"compilerOptions": {
44
"module": "commonjs",
5-
"target": "es6",
5+
"target": "es2019",
66
"outDir": "out",
77
"moduleResolution": "node",
88
"lib": ["esnext", "dom"],

0 commit comments

Comments
 (0)