-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Migrate from tsimp to swc using an import shim to mitigate the bn.js import bug * Updating version to 3.1.27 * Try a shorter sleep --------- Co-authored-by: dc-autobot[bot] <181364585+dc-autobot[bot]@users.noreply.github.com>
- Loading branch information
1 parent
eeca5e8
commit f79af40
Showing
12 changed files
with
2,130 additions
and
130 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,6 @@ src/swagger.json | |
src/routes.ts | ||
dist | ||
coverage | ||
.tsimp | ||
|
||
.npm | ||
.env | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"$schema": "https://swc.rs/schema.json", | ||
"jsc": { | ||
"parser": { | ||
"syntax": "typescript", | ||
"tsx": false, | ||
"decorators": true, | ||
"dynamicImport": true, | ||
"importMeta": true | ||
}, | ||
"transform": { | ||
"decoratorMetadata": true, | ||
"legacyDecorator": true, | ||
"useDefineForClassFields": true | ||
}, | ||
"target": "es2022" | ||
}, | ||
"exclude": [ | ||
"/__test__/" | ||
], | ||
"sourceMaps": true, | ||
"isModule": true, | ||
"minify": false | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { resolve as swcResolve } from '@swc-node/register/esm' | ||
export { load } from '@swc-node/register/esm' | ||
|
||
const skipSwcSet = new Set(['bn.js']) | ||
|
||
export function resolve(specifier, context, nextResolve) { | ||
if (skipSwcSet.has(specifier)) { | ||
return nextResolve(specifier, context) | ||
} | ||
return swcResolve(specifier, context, nextResolve) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
import { register } from 'node:module' | ||
|
||
register('./hooks.mjs', import.meta.url) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"exec": "node --import=@digicatapult/tsimp/import src/index.ts", | ||
"exec": "node --import=./import/index.mjs src/index.ts", | ||
"watch": ["src"], | ||
"ext": "ts" | ||
} |
Oops, something went wrong.