@itkyk/esbuild-plugin-babel
v0.0.3
Published
This package is for using babel with esbuild. In the plugin, `babel.transfromSync` works.
Downloads
22
Maintainers
Readme
esbuild-plugin-babel
This package is for using babel with esbuild.
In the plugin, babel.transfromSync
works.
Installation
To install the package, simply run the following command in your terminal:
npm i -D @itkyk/esbuild-plugin-babel
Usage
import * as esbuild from "esbuild";
import babelPlugin from "@itkyk/esbuild-plugin-babel";
await esbuild.build({
//...
plugins: [
babelPlugin({
presets:["@babel/preset-env"],
plugins: ["@babel/plugin-transform-runtime"]
})
]
//...
})
Options Reference
filter
| | | |-------------|------| | default | /.*/ | | description | You can specify the pattern of files to be read. |
babel
| | | |-------------|-------------------------------------------------| | default | {} | | description | babel settings can be added. |
Dependencies
- @babel/core: ^7.20.12
Change Log
- version 0.0.3 (2023/02/16)
- Fixed
babel.transformSync
filename option to default to the path of the file loaded by esBuild.
- Fixed