@jonaslideen/esbuild-register

1.2.0 • Public • Published

esbuild-register

Install

yarn add esm esbuild-register --dev

You need esm as well because esbuild doesn't compile import and export statements to commonjs require.

esbuild is also required as a peer dependency.

Usage

node -r esm -r esbuild-register file.ts

It will use jsxFactory, jsxFragmentFactory and target options from your tsconfig.json

When using Yarn, you can add an npm script:

"ts": "node -r esm -r esbuild-register"

to shorten the command, now just run yarn ts file.ts instead.

License

MIT © EGOIST (Kevin Titor)

Readme

Keywords

none

Package Sidebar

Install

npm i @jonaslideen/esbuild-register

Weekly Downloads

1

Version

1.2.0

License

MIT

Unpacked Size

5.45 kB

Total Files

7

Last publish

Collaborators

  • jonaslideen