#Internal server error: Failed to parse source for import analysis because..

1 messages · Page 1 of 1 (latest)

quiet junco
#

**Error: **"Internal server error: Failed to parse source for import analysis because the content contains invalid JS syntax. If you use tsconfig.json, make sure to not set jsx to preserve."

Anyone come across the npm start runtime error for the ; in main.jsx? I think it might be some incomplete jsx somewhere else triggering this

pure belfry
#

Is this with a brand new project. Cannot help if I can't see more code

#

Can u give ur Vite config and tsconfig

quiet junco
pure belfry
#

if you remove the esbuild config option, will it work?

quiet junco
#

Okay that resolved that one, thank you! I'm bulldosing through the rest for npm start, currently stuck on I believe the last one since all the other's disappeared

pure belfry
#

You don't import it like that

#

if you wrote the UserContext yourself, you need to import it using relative paths (i.e. using ./ if same folder, or ../ to go to parent folder)

#

same for other imports. Like how you did for SignupPageOverallFetch

#

example import UserProvider from './context/UserProvider