0.1.7 โ€ข Published 3 years ago

@leonardssh/rollup-plugin-swc v0.1.7

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

Remember to ๐ŸŒŸ this Github if you ๐Ÿ’– it.

๐Ÿ“ฆ Installation

  • Using yarn: yarn add -D @leonardssh/rollup-plugin-swc @swc/core
  • Using npm: npm i --save-dev @leonardssh/rollup-plugin-swc @swc/core
  • Using pnpm: pnpm add -D @leonardssh/rollup-plugin-swc @swc/core

๐Ÿค“ Usage

// rollup.config.js

import { swcPlugin } from '@leonardssh/rollup-plugin-swc';

export default {
	input: 'index.ts',
	output: {
		dir: 'dist',
		format: 'es'
	},
	plugins: [
		swcPlugin({
			jsc: {
				parser: {
					syntax: 'typescript'
				},
				target: 'es2018'
			}
		})
	]
};

๐Ÿ› ๏ธ Options

The plugin takes all the SWC options except the filename.

๐Ÿ‘จโ€๐Ÿ’ป Contributing

To contribute to this repository, feel free to create a new fork of the repository and submit a pull request.

  1. Fork / Clone and select the main branch.
  2. Create a new branch in your fork.
  3. Make your changes.
  4. Commit your changes, and push them.
  5. Submit a Pull Request here!

๐Ÿ“‹ License

This project is licensed under the MIT License - see the LICENSE file for details.