LoginSignup
2
3

More than 3 years have passed since last update.

Laravel npm installを実行しようとしたらエラーが出た話 超簡易版

Posted at

目的

  • Laravelアプリに必要なJSパッケージをインストールするためにnpm installを実行したがエラーが出た話をまとめる

問題までの経緯

  1. Laravelアプリ名ディレクトリの一つ上の階層で下記コマンドを実行した。

    $ npm install
    

問題

  1. 下記エラーが発生しコマンドが正常実行されない。

    npm WARN saveError ENOENT: no such file or directory, open '/usr/share/nginx/html/package.json'
    npm WARN enoent ENOENT: no such file or directory, open '/usr/share/nginx/html/package.json'
    npm WARN html No description
    npm WARN html No repository field.
    npm WARN html No README data
    npm WARN html No license field.
    
    audited 15 packages in 0.511s
    
    3 packages are looking for funding
      run `npm fund` for details
    
    found 0 vulnerabilities
    

問題解決までの経緯

  1. $ npm installを実行するディレクトリを間違えていた。
  2. Laravelアプリ名ディレクトリに移動して$ npm installを実行したところ正常に実行された。
2
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
3