How to force npm to use the jquery 2.1.1

只谈情不闲聊 提交于 2019-12-04 04:58:35

Add the specific version to your package.json file

"dependencies": {
    "jquery": "2.1.1"
}

You can use the npm CLI to install the dependency directly without changing the dependencies yourself in package.json by typing:

npm install jquery@2.1.1

Thanks for helping out. I went to my package.json file and added dependency as

"dependencies": {
  "jquery": "2.1.1"
}

after this I did sudo npm update to the existing project and it changed the jquery version to 2.1.1. I assume sudo npm install would also have same effect

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!