0.0.9 • Published 5 years ago
@bundl/jsx v0.0.9
@bundl/jsx
JSX Plugin for Bundl.
Note that it doesn't compile using Babel. For Babel use this plugin.
Installation
# npm
npm i -D @bundl/jsx
# yarn
yarn add -D @bundl/jsx
Usage
const jsx = require('@bundl/jsx')
module.exports = {
output: {
'build/bundle.js': {
use: jsx(),
input: 'src/*.js'
}
}
}
Custom JSX factory
This plugin uses jsx-transform so all options are inherited from it.
const jsx = require('@bundl/jsx')
module.exports = {
output: {
'build/bundle.js': {
use: jsx({ factory: 'preact.h' }),
input: 'src/*.js'
}
}
}