inferno-styled-jsx
v0.0.1
Published
Use styled-jsx with Inferno
Downloads
5
Readme
inferno-styled-jsx
Write styled-jsx in Inferno.
Setup
npm install --save-dev iferno-styled-jsx
Configuring
In your babel config, configure styled-jsx as documented. Make sure that you configure styleModule='inferno-styled-jsx/style'
as in the following example:
["styled-jsx/babel", { "optimizeForSpeed": true, "styleModule": "inferno-styled-jsx/style" }],
Example
function Example() {
return (
<div class="bigtext">
Hi, there. I'm a large font.
<style jsx>
{`
.bigtext {
font-size: 5rem;
color: green;
}
`}
</style>
</div>
);
}