A library to enable maquette to use jsx
npm install maquette-jsx``jsx`
let render = () => {
return ;
{ nameInput.render() }
Hello {name || 'you'}!
}
- When using Typescript: Add the following lines to your tsconfig.json:
- "jsx": "react"
- "jsxFactory": "jsx"
- When using babel: Add the following plugin:
- "plugins": [ ["transform-react-jsx", {"pragma": "jsx"}] ]
- Call maquette-jsx's enableGlobalJsx function before calling maquette's createProjector()
- You can now return JSX from your render` functions