TypeStrong/ts-node
### [`v10.1.0`](https://togithub.com/TypeStrong/ts-node/releases/v10.1.0)
[Compare Source](https://togithub.com/TypeStrong/ts-node/compare/v10.0.0...v10.1.0)
Questions about this release? Ask in the official discussion thread: [#1390](https://togithub.com/TypeStrong/ts-node/issues/1390)
**Added**
- Add `"moduleType"` option to override module type -- CommonJS or ECMAScript -- on select files. ([docs](https://typestrong.org/ts-node/docs/module-type-overrides)) ([#1342](https://togithub.com/TypeStrong/ts-node/issues/1342), [#1371](https://togithub.com/TypeStrong/ts-node/issues/1371), [#1376](https://togithub.com/TypeStrong/ts-node/issues/1376))
- Useful when a configuration file, for example `webpack.config.ts`, must execute as CommonJS but the rest of the project is ESM
- selectively overrides `package.json` `"type"` and `tsconfig.json` `"module"`
- akin to `.cjs` and `.mjs` extensions, but for `.ts` and `.tsx` files
- thanks to [@jayaddison](https://togithub.com/jayaddison) for help on test coverage
- Implement `"extends"` support for `"ts-node"` options in `tsconfig.json` ([#1328](https://togithub.com/TypeStrong/ts-node/issues/1328), [#1356](https://togithub.com/TypeStrong/ts-node/issues/1356))
- `"ts-node": {}` options will be parsed from extended tsconfigs
- allows sharing and deduplicating ts-node configuration
- Un-deprecate `scope` and `scopeDir`; add both to CLI and `tsconfig.json` options; un-deprecate `TS_NODE_SCOPE` env var; add `TS_NODE_SCOPE_DIR` env var ([docs](https://typestrong.org/ts-node/docs/options)) ([#1346](https://togithub.com/TypeStrong/ts-node/issues/1346), [#1367](https://togithub.com/TypeStrong/ts-node/issues/1367))
**Changed**
- Improve error messages thrown by native ESM loader hooks ([#1357](https://togithub.com/TypeStrong/ts-node/issues/1357), [#1373](https://togithub.com/TypeStrong/ts-node/issues/1373)) [@tars0x9752](https://togithub.com/tars0x9752)
- messages more closely match node; are more descriptive
- Emit `"ts-node"` object at the top of `--showConfig` output instead of the bottom ([#1355](https://togithub.com/TypeStrong/ts-node/issues/1355))
**Fixed**
- Fix [#1282](https://togithub.com/TypeStrong/ts-node/issues/1282): Set correct globals in `[stdin]`, `[eval]`, and `` contexts ([#1333](https://togithub.com/TypeStrong/ts-node/issues/1333))
- More closely align ts-node's behavior with vanilla node
- Affects the interactive REPL, piping to stdin, and `ts-node -e`
- Matches node's behavior for globals `__filename`, `__dirname`, `module` and sub-fields of `module`, `exports`, and builtin module aliases `fs`, etc
- Fix [#1343](https://togithub.com/TypeStrong/ts-node/issues/1343): Set swc option `keepClassNames` to `true` ([#1344](https://togithub.com/TypeStrong/ts-node/issues/1344))
- Fix: [#1387](https://togithub.com/TypeStrong/ts-node/issues/1387): REPL outputs 'use strict' after first empty line of input ([#1388](https://togithub.com/TypeStrong/ts-node/issues/1388)) [@ejose19](https://togithub.com/ejose19)
**Docs**
- Update ESM docs to say that env vars *are* supported with `node --loader ts-node/esm` ([docs](https://togithub.com/TypeStrong/ts-node/issues/1007)) ([#1379](https://togithub.com/TypeStrong/ts-node/issues/1379))
https://github.com/TypeStrong/ts-node/milestone/3
Configuration
📅 Schedule: At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
[ ] If you want to rebase/retry this PR, check this box.
This PR contains the following updates:
10.0.0
->10.1.0
Release Notes
TypeStrong/ts-node
### [`v10.1.0`](https://togithub.com/TypeStrong/ts-node/releases/v10.1.0) [Compare Source](https://togithub.com/TypeStrong/ts-node/compare/v10.0.0...v10.1.0) Questions about this release? Ask in the official discussion thread: [#1390](https://togithub.com/TypeStrong/ts-node/issues/1390) **Added** - Add `"moduleType"` option to override module type -- CommonJS or ECMAScript -- on select files. ([docs](https://typestrong.org/ts-node/docs/module-type-overrides)) ([#1342](https://togithub.com/TypeStrong/ts-node/issues/1342), [#1371](https://togithub.com/TypeStrong/ts-node/issues/1371), [#1376](https://togithub.com/TypeStrong/ts-node/issues/1376)) - Useful when a configuration file, for example `webpack.config.ts`, must execute as CommonJS but the rest of the project is ESM - selectively overrides `package.json` `"type"` and `tsconfig.json` `"module"` - akin to `.cjs` and `.mjs` extensions, but for `.ts` and `.tsx` files - thanks to [@jayaddison](https://togithub.com/jayaddison) for help on test coverage - Implement `"extends"` support for `"ts-node"` options in `tsconfig.json` ([#1328](https://togithub.com/TypeStrong/ts-node/issues/1328), [#1356](https://togithub.com/TypeStrong/ts-node/issues/1356)) - `"ts-node": {}` options will be parsed from extended tsconfigs - allows sharing and deduplicating ts-node configuration - Un-deprecate `scope` and `scopeDir`; add both to CLI and `tsconfig.json` options; un-deprecate `TS_NODE_SCOPE` env var; add `TS_NODE_SCOPE_DIR` env var ([docs](https://typestrong.org/ts-node/docs/options)) ([#1346](https://togithub.com/TypeStrong/ts-node/issues/1346), [#1367](https://togithub.com/TypeStrong/ts-node/issues/1367)) **Changed** - Improve error messages thrown by native ESM loader hooks ([#1357](https://togithub.com/TypeStrong/ts-node/issues/1357), [#1373](https://togithub.com/TypeStrong/ts-node/issues/1373)) [@tars0x9752](https://togithub.com/tars0x9752) - messages more closely match node; are more descriptive - Emit `"ts-node"` object at the top of `--showConfig` output instead of the bottom ([#1355](https://togithub.com/TypeStrong/ts-node/issues/1355)) **Fixed** - Fix [#1282](https://togithub.com/TypeStrong/ts-node/issues/1282): Set correct globals in `[stdin]`, `[eval]`, and `Configuration
📅 Schedule: At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by WhiteSource Renovate. View repository job log here.