Just create a .babelrc
file in the root of your project and add:
{
"presets": ["@babel/preset-env", "@babel/preset-react"]
}
More Related Contents:
- How to Protect website code PHP / JS? [closed]
- How to create a translucent in React Native?
- Why calling setState method doesn’t mutate the state immediately?
- Insert HTML with React Variable Statements (JSX) [duplicate]
- Render HTML string as real HTML in a React component
- When to use functional setState
- Concatenating variables and strings in React
- ReactJS – .JS vs .JSX
- How to render HTML string as real HTML?
- ReactJS: “Uncaught SyntaxError: Unexpected token
- How to add custom html attributes in JSX
- javascript change background color on click [closed]
- React: how to load and render external html file?
- Updating source URL on HTML5 video with React
- Where’s the connection between index.html and index.js in a Create-React-App application?
- css position absolute making the textbox go down
- TypeError [ERR_INVALID_ARG_TYPE]: The “path” argument must be of type string. Received type undefined raised when starting react app
- How do you import a javascript package from a cdn/script tag in React?
- Adding a new line in a JSX string inside a paragraph – React
- React.js this.props.data.map() is not a function
- Using Matter.js to render to the DOM or React
- React: Script tag not working when inserted using dangerouslySetInnerHTML
- render html in state string [duplicate]
- React, losing saved data in localStorage with useEffect after page refresh
- Infinite scrolling with React JS
- Images not loading when relative path is used in React
- Next.js: Error: React.Children.only expected to receive a single React element child
- Measuring text width/height without rendering
- minimise the code since I am using the same code only the content in p tags changes and component AccordionHeader header changes
- How to parse html to React component?