babel-plugin-transform-nojsx
v0.1.2
Published
Transpile plugin for custom components using nojsx.
Downloads
3
Maintainers
Readme
nojsx
Transpile plugin for custom components using nojsx.
This is a protest module against JSX. JSX breaks javascript. This does not.
A tiny bit of JS transpiling is needed to have a seamless experience with nojsx.
Install
npm install --save babel-plugin-transform-nojsx
.babelrc
{
"presets": [
...
],
"plugins": [
...
"transform-nojsx"
]
}
Before Transpiling
html`<div>Hello. <AnotherThing></AnotherThing></div>`
After Transpiling
html`<div>Hello. <AnotherThing higherComponent=${AnotherThing}></AnotherThing></div>`
It simply allows for upper-context component function / object reference.
Notes
- Not tested
- Not production ready
- Safer transpiling to come
- Try for small projects and apps
- All feedback is welcome
License
MIT.