Reputation: 582
I have a react preset, and I want to pass pragma params to transform-react-jsx.
For now I’m installing transform-react-jsx separatly and set my .babelrc
like so:
{
"presets": [
"react"
],
"plugins": [
["transform-react-jsx", {
"pragma": "dom.hJSX"
}]
]
}
But I wonder if there is another way to pass settings to plugins in presets.
Upvotes: 6
Views: 1796
Reputation: 582
So I got to babel github and as I found out now there is no way to pass settings to plugins in presets.
On the bright side there is another discussion that could turn into something sometime sooner or later.
UPD: babel moved all issues to phabricator and these discussions seem to be lost forever. However this feature seems to be a step forward towards solving the issue.
Upvotes: 2