1

I'm using Laravel 9. When I try to run npm install, then run npm run dev, the error below shows up.

VITE v3.0.9  ready in 648 ms

  ➜  Local:   http://127.0.0.1:5173/
  ➜  Network: use --host to expose

  LARAVEL v9.26.0  plugin v0.5.4

  ➜  APP_URL: http://127.0.0.1:8000
C:\Software Project\Web Development\AdminPanel\node_modules\esbuild\lib\main.js:1356
        return callback(new Error(error), null);
                        ^

Error: The service was stopped: write EPIPE
    at C:\Software Project\Web Development\AdminPanel\node_modules\esbuild\lib\main.js:1356:25    
    at C:\Software Project\Web Development\AdminPanel\node_modules\esbuild\lib\main.js:678:9      
    at afterClose (C:\Software Project\Web Development\AdminPanel\node_modules\esbuild\lib\main.js:656:7)
    at C:\Software Project\Web Development\AdminPanel\node_modules\esbuild\lib\main.js:2075:11    
    at onwriteError (node:internal/streams/writable:417:3)
    at processTicksAndRejections (node:internal/process/task_queues:85:21)
8
  • What version of esbuild are you using in your package.json? Commented Aug 24, 2022 at 13:37
  • the version im using is "0.14.54" Commented Aug 24, 2022 at 21:51
  • Perhaps try to upgrade the package: npm install esbuild@latest Commented Aug 24, 2022 at 22:21
  • $ npm run dev > dev > vite failed to load config from C:\Software Project\Web Development\AdminPanel\vite.config.js error when starting dev server: ReferenceError: os is not defined at Object.<anonymous> (C:\Software Project\Web ....... Commented Aug 24, 2022 at 22:40
  • 1
    Not sure how to help you besides removing /node_modules directory and running npm install again. Commented Aug 24, 2022 at 23:11

1 Answer 1

2

The problem appeared with versions above 9.0

Download a new Laravel project

Type the following command and your problem will be solved

composer create-project laravel/laravel example-app 9.0

The following commands will work successfully npm install, and npm run dev

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.