When executing `npm run dev` I encountered the following error
P粉819533564
P粉819533564 2023-08-15 22:50:05
0
1
533
<p>C:UserssamyJobssahl_project>npm run dev</p> <blockquote> <p>sahl_project@1.0.0 dev vite</p> </blockquote> <p>X [ERROR] Expected string in JSON but found "<<"</p> <pre class="brush:php;toolbar:false;">../package.json:2:0: 2 │ <<<<<<< HEAD ╵ ~~</pre> <p>Unable to load configuration file from C:UserssamyJobssahl_projectvite.config.js Error starting development server: Error: Build failed with 1 error: ../package.json:2:0: Error: Expected string in JSON but found "<<"</p> <p>I tried deleting package-lock.json and node_modules folders and executing npm install, but it didn’t work</p>
P粉819533564
P粉819533564

reply all(1)
P粉446800329

It can be difficult to determine the specific source of the problem, but there are a few things you can try to resolve it:

  1. Try using git diff --name-only --diff-filter=U --relative to check for merge conflicts and list the files causing the problem.
  2. Before running npm run dev, try running npm ci.
  3. Try to newly clone the project in a different location and run npm i on the master branch, then run npm run dev to see if the problem persists.
  4. Check that you are using the correct Node version that is compatible with your project node -v.
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!