Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README to include mjs, mts, cts, cjs under "Ignored files" > "File extensions" #2074

Open
wants to merge 1 commit into
base: docs
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion website/docs/scope.md
Expand Up @@ -13,10 +13,12 @@ options to configure scoping, so that ts-node transforms only the files in your

## File extensions

`.js` and `.jsx` are only transformed when [`allowJs`](https://www.typescriptlang.org/docs/handbook/compiler-options.html#compiler-options) is enabled.
`.js`, `.jsx`, `.mjs`, and `.cjs` are only transformed when [`allowJs`](https://www.typescriptlang.org/docs/handbook/compiler-options.html#compiler-options) is enabled.

`.tsx` and `.jsx` are only transformed when [`jsx`](https://www.typescriptlang.org/docs/handbook/jsx.html) is enabled.

`.mts`, `.cts`, `.mjs`, and `.cjs` are only transformed for TypeScript versions >= 4.5.0.

> **Warning:**
>
> When ts-node is used with `allowJs`, _all_ non-ignored JavaScript files are transformed by ts-node.
Expand Down