Skip to content

Plugin for esbuild to support tranforming js(x)/ts(x) with swc.

License

Notifications You must be signed in to change notification settings

sanyuan0704/esbuild-plugin-swc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

esbuild-plugin-swc

Plugin for esbuild to support tranforming js(x)/ts(x) with swc.

Install

// if using npm
npm i -D esbuild-plugin-swc
// if using yarn
yarn add -D esbuild-plugin-swc
// if using pnpm
pnpm i -D esbuild-plugin-swc

Usage example

const esbuild = require('esbuild');
const { swcPlugin } = require('esbuild-plugin-swc');
esbuild.build({
  entryPoints: ['./index.tsx'],
  bundle: false,
  outdir: 'out',
  plugins: [
    swcPlugin()
  ]
})

Options

When instantiating plugin you can pass an objects with options. This object has SWC official Compilation type, see detail in Compilation

About

Plugin for esbuild to support tranforming js(x)/ts(x) with swc.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published