File tree 3 files changed +12
-3
lines changed
3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 378
378
"js-yaml" : " ^4.0.0" ,
379
379
"jszip" : " ^3.7.1" ,
380
380
"mocha" : " ^9.1.3" ,
381
- "node-fetch" : " ^3.x" ,
382
381
"path-browserify" : " ^1.0.1" ,
383
382
"process" : " ^0.11.10" ,
384
383
"rimraf" : " ^3.0.2" ,
389
388
"webpack" : " ^5.64.4" ,
390
389
"webpack-cli" : " ^4.9.1"
391
390
},
391
+ "dependencies" : {
392
+ "node-fetch" : " ^3.x"
393
+ },
392
394
"repository" : {
393
395
"type" : " git" ,
394
396
"url" : " https://github.com/dosasm/masm-tasm"
398
400
399
401
},
400
402
"license" : " MIT"
401
- }
403
+ }
Original file line number Diff line number Diff line change 2
2
* API for downloading information from web
3
3
*/
4
4
import { logger } from "./logger" ;
5
- import fetch from "node- fetch" ;
5
+ import { fetch } from "./ fetch" ;
6
6
7
7
export async function downloadFromMultiSources ( urls : string [ ] ) : Promise < string | undefined > {
8
8
for ( const url of urls ) {
Original file line number Diff line number Diff line change
1
+ /* eslint-disable @typescript-eslint/no-explicit-any */
2
+ // @ts -check
3
+
4
+ export const fetch =
5
+ process . platform
6
+ ? eval ( "(...args) => import('node-fetch').then(({default: fetch}) => fetch(...args))" )
7
+ : window . fetch ;
You can’t perform that action at this time.
0 commit comments