Skip to content

Commit

Permalink
Use esbuild-register instead of ts-node (#53)
Browse files Browse the repository at this point in the history
* Use esbuild-register instead of ts-node

* Alias esbuild-register to typescript-register as `interpret` doesn't know ESBuild exists

See:
- gulpjs/interpret#74
- https://github.dev/webpack/webpack-cli/blob/b39dfb68fc478194c438d128ed1f7232a5346a1c/packages/webpack-cli/src/webpack-cli.ts#L1796
  • Loading branch information
robertfischman committed Nov 21, 2024
1 parent c0189e1 commit c095129
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 101 deletions.
2 changes: 1 addition & 1 deletion .mocharc.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
require: ["ts-node/register/transpile-only"],
require: ["esbuild-register"],
extension: ["ts"],
watchExtensions: ["ts"],
// Extension tests run inside of VSCode instance, so we don't include them here
Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@
"@typescript-eslint/parser": "^5.3.0",
"assert": "^2.0.0",
"earljs": "^0.1.12",
"esbuild": "^0.14.10",
"esbuild-register": "^3.3.2",
"typescript-register": "npm:esbuild-register@^3.3.2",
"eslint": "^7",
"eslint-config-typestrict": "^1.0.2",
"eslint-plugin-import": "^2.25.2",
Expand All @@ -37,7 +40,6 @@
"process": "^0.11.10",
"serve": "^13.0.2",
"ts-loader": "^9.2.5",
"ts-node": "^10.4.0",
"typescript": "^4.5.3",
"webpack": "^5.52.1",
"webpack-cli": "^4.8.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/ethereum-viewer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"pretest": "yarn run build",
"lint": "eslint src --ext ts",
"serve": "serve --cors -l 5000 --ssl-cert ../../certs/localhost.pem --ssl-key ../../certs/localhost-key.pem",
"supported-explorers": "ts-node ./scripts/supported-explorers"
"supported-explorers": "node -r esbuild-register ./scripts/supported-explorers"
},
"dependencies": {
"fast-json-stable-stringify": "^2.1.0",
Expand Down
124 changes: 26 additions & 98 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit c095129

Please # to comment.