13
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

M1 Mac node.js v15 と Intel Mac node.js v14 で package-lock.json の lockfileVersion が違う

Last updated at Posted at 2021-01-07

Apple Silicon M1 arm64 aarch64 Mac 環境の node.js v15 では、
npm v7 によって package-lock.json が "lockfileVersion": 2 になる。

従来の Intel x64 amd64 Mac 環境などの node.js v14 では、
npm v6 によって package-lock.json が "lockfileVersion": 1 になっていた。

v14 と v15 を併用する場合は、npm のバージョンを揃えたほうが良さそう。
当面 production で npm v6 を使うなら

npm install -g npm@6

として、M1 Mac 側を v6 にダウングレードすることで、バージョンを揃えることができる。

13
4
1

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
13
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?