Closed MuYunyun closed 6 years ago
:man_shrugging: works for me. Did you npm install --save-dev babel-plugin-jsx-control-statements
or npm install --save-dev jsx-control-statements
?
I do yarn add babel-plugin-jsx-control-statements
.I doubt if the plugin's incompatible in the low version babel(6.x) or be covered by other plugin(not only babel-plugin-syntax-jsx)?
emm, I‘ve found the reason. The Project actually has two .babelrc
, and I change the error one. 😭
:joy: :+1:
I do as the step readme show. Howerver, the browser still error with Uncaught ReferenceError: Choose is not defined. This babel-plugin don't do effort in my app.
my jsx as follow:
This is my .babelrc
I use webpack to run my app, and the print as follow: