-
-
Notifications
You must be signed in to change notification settings - Fork 545
Closed
Milestone
Description
Add --scope
to the CLI and add scope
as an option which can be specified in tsconfig.json
Un-deprecate TS_NODE_SCOPE
Update docs
Update ts-node --help
output
Update: also added TS_NODE_SCOPE_DIR and --scope-dir
/ tsconfig scopeDir
in #1367
- double-check my old issues about
scope
to ensure there are no reasons against adding it totsconfig.json
Motivating use-case
Based on conversation starting here:
#693 (comment)
- The user has a monorepos,
./packages/a/node_modules/b
symlinks to./packages/b
- running tests and scripts in
./packages/a
allowJS
is enabled- code in
a
importsb
, which resolves to./packages/b/dist/index.js
- The user does not want
ts-node
to compile anything inb
; only ina
- philosophically, each package in the monorepo is a separate entity with its own build scripts
- One package should not make assumptions about its ability to transpile the source of another
rootDir
is./packages/a/src
butts-node
is running unit-tests in./packages/a/unit-tests
- This can be addressed by overriding
rootDir
forts-node
- This can be addressed by overriding
jeanlescure
Metadata
Metadata
Assignees
Labels
No labels