npm 安装库的路径略有不同是什么意思?
What do the slightly different paths to npm install libraries mean?
我见过 npm install
图书馆的两种不同方式。例如,查看 React 测试库:
npm install --save-dev @testing-library/react
npm install --save-dev react-testing-library
我对两条路径之间的差异(如果有的话)感到困惑?
编辑:我刚找到一个 issue regarding this specific library:
react-testing-library has moved to @testing-library/react. Please
uninstall react-testing-library and install @testing-library/react
instead, or use an older version of react-testing-library. Learn more
about this change here:
https://github.com/testing-library/dom-testing-library/issues/260
Thanks! :)
第一个命令是安装范围包的示例。这里,@testing-library
是一个包含包 react
的范围。使用范围是可选的,如果不使用(如在第二个命令中),它将从主要是 github.
的默认范围中获取它
有关 npm-scope
的更多详细信息,请阅读此处:https://docs.npmjs.com/misc/scope
我见过 npm install
图书馆的两种不同方式。例如,查看 React 测试库:
npm install --save-dev @testing-library/react
npm install --save-dev react-testing-library
我对两条路径之间的差异(如果有的话)感到困惑?
编辑:我刚找到一个 issue regarding this specific library:
react-testing-library has moved to @testing-library/react. Please uninstall react-testing-library and install @testing-library/react instead, or use an older version of react-testing-library. Learn more about this change here: https://github.com/testing-library/dom-testing-library/issues/260 Thanks! :)
第一个命令是安装范围包的示例。这里,@testing-library
是一个包含包 react
的范围。使用范围是可选的,如果不使用(如在第二个命令中),它将从主要是 github.
有关 npm-scope
的更多详细信息,请阅读此处:https://docs.npmjs.com/misc/scope