如何安全地删除 resolve-url?

How to safely remove resolve-url?

我有一个 npm 包 resolve-url in my React Native project. The package is deprecated, and I'm not using it, so I want to remove it. However, after I run npm uninstall resolve-url to uninstall per npm's documentation,我的项目不再运行 npm start


如何安全地删除 resolve-url?

How do I safely remove resolve-url?


事实证明,我的项目通过另一个包 source-map-resolve 依赖于 resolve-url。

解决方案:

  1. npm uninstall source-map-resolve
  2. npm uninstall resolve-url
  3. 我删除了新创建的package-lock.json,因为我的项目使用了yarn.lock
  4. 我清理了 yarn.lock.
  5. 中对 source-map-resolve 和 resolve-url 的剩余引用

More info