Registry / devops / esno
library4.8.0jsnpmunverified

A Node.js runtime enhanced with esbuild for loading TypeScript and ESM modules. Version 4.8.0 is current and stable, with frequent releases alongside tsx. esno is essentially an alias of tsx (formerly esno was separate, now merged into tsx package). Differentiator: auto CJS/ESM mode detection, seamless TypeScript execution without config, and caching for faster reloads. Suitable for scripts, CLIs, and development servers.

npm install esno
INSTALL
IMPORT
SIG · ESNO
E
esno
devopsjavascriptv4.8.0
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18223 runs
build_error
glibc
node 18223 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

default
import esno from 'esno'
const esno = require('esno')
esno provides a CLI only, not a programmatic API. The default import is a no-op function; use tsx for programmatic usage.
tsx
import 'tsx'
import 'esno'
For programmatic transform, import 'tsx' directly (esno delegates to tsx).
require('esno')
node -r esno/register script.ts
require('esno')
esno's register hook is not a CommonJS module; use the -r flag.

Run a TypeScript file directly using esno, which transpiles with esbuild and executes with Node.js.

npx esno hello.ts
esno --version
Debug
Known issues
breakingFrom v0.15, esno is an alias of tsx; all issues must be reported in esbuild-kit/tsx.
fix
Use tsx package instead for new projects or if you need programmatic API.
affects: >=0.15
deprecatedThe 'esno' package itself is deprecated in favor of 'tsx'.
fix
Migrate to 'tsx' for future updates and support.
affects: >=0.15
gotchaesno does not provide a programmatic API; importing it is a no-op.
fix
Use 'tsx' package for transform or register hooks in code.
affects: >=0.15
gotchaIf using require('esno'), it will not register the TypeScript loader; use -r esno/register.
fix
Use node -r esno/register script.ts instead of programmatic require.
affects: >=0.15
Errors
Common errors & fixes
ERR_MODULE_NOT_FOUND: Cannot find module 'esno' imported from
Using esno as a programmatic import but it's a CLI-only package.
fix
Use 'tsx' package: import 'tsx' or use npx tsx.
TypeError: esno is not a function
Importing esno as a function, but the default export is a no-op.
fix
Use tsx for programmatic usage: import 'tsx'.
Error: Cannot find module 'esno/register'
The register path was removed; esno delegates to tsx.
fix
Use node -r tsx/register script.ts instead.
Warning: esno is deprecated; use tsx instead.
esno is now an alias of tsx.
fix
Switch to tsx: npm uninstall -g esno && npm install -g tsx
Upgrade
Version history
4.8.0latest on npm
Audit
Dependencies
tsxrequiredesno v0.15+ is an alias of tsx, which is the core runtime
Agent activity
4 hits · last 30 days
node
4
Resources
esno — npm install esno · libregistry