Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

173
Views
One more: Support for the experimental syntax 'jsx' isn't currently enabled ==> checked other answers, didn't work

I'm following https://medium.com/swlh/how-to-setup-a-react-js-project-from-scratch-e746a77ffed4 to set up a React project manually.

My bable.config.json contains:

 % more bable.config.json
{
  "presets": [
     "@babel/preset-env",
     "@babel/preset-react"
  ],
  "comments": false
}

When executing npx babel index.jsx --out-dir lib I get this error:

SyntaxError: frontend-react/index.jsx: Support for the experimental syntax 'jsx' isn't currently enabled (10:5):

   8 | const App = () => {
   9 |   return (
> 10 |     <>
     |     ^
  11 |       <h1>Congrats!</h1>
  12 |       <h3>You have successfully setup React.JS from scratch</h3>
  13 |     </>

Add @babel/preset-react (https://git.io/JfeDR) to the 'presets' section of your Babel config to enable transformation.
If you want to leave it as-is, add @babel/plugin-syntax-jsx (https://git.io/vb4yA) to the 'plugins' section to enable parsing.
    at Parser._raise (frontend-react/node_modules/@babel/parser/lib/index.js:541:17)
    at Parser.raiseWithData (frontend-react/node_modules/@babel/parser/lib/index.js:534:17)
    at Parser.expectOnePlugin (frontend-react/node_modules/@babel/parser/lib/index.js:3602:18)
    at Parser.parseExprAtom (frontend-react/node_modules/@babel/parser/lib/index.js:11961:18)
    at Parser.parseExprSubscripts (frontend-react/node_modules/@babel/parser/lib/index.js:11564:23)
    at Parser.parseUpdate (frontend-react/node_modules/@babel/parser/lib/index.js:11544:21)
    at Parser.parseMaybeUnary (frontend-react/node_modules/@babel/parser/lib/index.js:11519:23)
    at Parser.parseMaybeUnaryOrPrivate (frontend-react/node_modules/@babel/parser/lib/index.js:11333:61)
    at Parser.parseExprOps (frontend-react/node_modules/@babel/parser/lib/index.js:11340:23)
    at Parser.parseMaybeConditional (frontend-react/node_modules/@babel/parser/lib/index.js:11310:23) {
  loc: Position { line: 10, column: 4 },
  pos: 337,
  missingPlugin: [ 'jsx', 'flow', 'typescript' ],
  code: 'BABEL_PARSE_ERROR'
}

It seems like the bable.config.json file isn't used.

I read and tried all answers I could find (like adding .bablerc, etc.) but nothing helped or worked.

The missingPlugin error looks suspicious to me but might be a side effect.

So, how to find out what's going on or is there anything else I could try?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!