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

364
Views
nuxt fails with an error not being able to parse source for import analysis

When I attempt to make the server, it throws up a 500 error and the following error is shown in the terminal:

[SSR] Error transforming  virtual:C:/Users/User/Documents/CODING/Ted's/.nuxt/plugins/server.mjs: Failed to parse source for import analysis because the content contains invalid JS syntax. If you are using JSX, make sure to name the file with the .jsx or .tsx extension.

I've attempted to run npm cache clean --force I've reinstalled npm numerous times, given Everyone full privs for the dir it is in, ran VSCode as admin, I'm out of ideas.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

The problem is most certainly related to those issues:

  • github/nuxt: incompatible with paths with ' in the filename #2192
  • github/nuxt: fix: escape dynamic import paths #4286

This PR addresses issues when using rollup for a project with ' in the path, for example /Users/Daniel's Projects/project/. Although normal imports are escaped correctly, it seems that dynamic imports are treated differently and we need to escape them as well.

Your path C:/Users/User/Documents/CODING/Ted's/ contains a ' and according to the issue this results in that problem.

So the solution to the problem is to get rid of that ' in your path, or wait until a version of nuxt is released that fixes that problem.

given Everyone full privs for the dir it is in, ran VSCode as admin, I'm out of ideas.

That is something you should never do. There are only really rare cases where you probably might need that, and even then you should rethink that multiple times. Running VSCode as admin would allow vscode and all its installed plugins to mess around with a large amount of the system. If you do that you need to fully trust all of those.

about 4 years ago · Juan Pablo Isaza Report
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!