| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
Runtime Typescript and ESM support for Node.js.
Important
This is the support branch for jiti v1. Check out jiti/main for the latest version and unjs/jiti#174 for the roadmap.
const jiti = require("jiti")(__filename);
jiti("./path/to/file.ts");You can also pass options as second argument:
const jiti = require("jiti")(__filename, { debug: true });jiti index.ts
# or npx jiti index.tsnode -r jiti/register index.tsAlternatively, you can register jiti as a require hook programmatically:
const jiti = require("jiti")();
const unregister = jiti.register();Enable debug to see which files are transpiled
Use transpile cache
If set to true will use node_modules/.cache/jiti (if exists) or {TMP_DIR}/node-jiti
Using esm resolution algorithm to support import condition.
Transform function. See src/babel for more details
Add inline source map to transformed source for better debugging.
Return the .default export of a module at the top-level.
Custom alias map used to resolve ids.
List of modules (within node_modules) to always use native require for them.
List of modules (within node_modules) to transform them regardless of syntax.
Enable experimental native Bun support for transformations.
MIT. Made with 💖
| Back | FazBrowse Home | New Git URL |