Skip to content

Commit

Permalink
only parse the className when needed
Browse files Browse the repository at this point in the history
  • Loading branch information
RobinMalfait committed Aug 16, 2020
1 parent 454a7b9 commit 051419f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/util/generateVariantFunction.js
Expand Up @@ -22,10 +22,10 @@ export default function generateVariantFunction(generator) {
}

rule.selectors = rule.selectors.map(selector => {
const className = classNameParser.transformSync(selector)

return modifierFunction({
className,
get className() {
return classNameParser.transformSync(selector)
},
selector,
})
})
Expand Down

0 comments on commit 051419f

Please sign in to comment.