Home>Article>Web Front-end> How to solve the error problem when writing react code in webstrom
The solution to webstrom's error when writing react code: first open the webstrom software; then open the corresponding react file; and finally set the JavaScript version to "JSX Harmony".
The operating environment of this tutorial: windows7 system, webstorm2020.3&&react16.4.0 version, Dell G3 computer.
Related recommendations: "react tutorial"
Using reactjs syntax to report errors in WebStorm
Set the JavaScript version to JSX Harmony. Generally, there will be a prompt for you to switch on the page where you write the react code. Just click the switch in the upper right corner;
If there is no prompt in the upper right corner, settings => ; Languages & Frameworks => JavaScript => Just change the JavaScript language version
The above is the detailed content of How to solve the error problem when writing react code in webstrom. For more information, please follow other related articles on the PHP Chinese website!