【问题标题】:ExtReact - npm ERR! 403 403 ForbiddenExtReact - npm 错误! 403 403 禁止
【发布时间】:2020-08-04 14:40:48
【问题描述】:

我正在尝试使用 ExtReact 的试用版并使用链接

https://docs.sencha.com/extreact/7.2.0/guides/getting_started/creating_ext_react_app_modern.html

所以,成功获取了用户名和密码,并且可以在第 2 步中登录。

但是在运行第 3 步时:使用 create-react-app 和 ExtReact 模板创建一个 React 应用程序不起作用。以下命令给出以下错误。

npx create-react-app --template @sencha/ext-react-modern ext-react-modern-demo

错误:

Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts with @sencha/cra-template-ext-react-modern...

npm ERR! code E403
npm ERR! 403 403 Forbidden - GET https://npm.sencha.com/@sencha%2fcra-template-ext-react-modern - unregistered users are not allowed to access package @sencha/cra-template-ext-react-modern
npm ERR! 403 In most cases, you or one of your dependencies are requesting
npm ERR! 403 a package version that is forbidden by your security policy.

【问题讨论】:

    标签: reactjs npm extjs extreact


    【解决方案1】:

    https://docs.sencha.com/extwebcomponents/7.0.0/guides/open_tooling_npm/npm_help.html

    Windows(命令提示符)

    1. 运行 del %HOMEPATH%.npmrc - 删除存储的 npm 存储库凭据。此位置在您的系统上可能不同。(或手动删除此文件在本地计算机中找到它)
    2. 运行 npm cache clean --force 或 rmdir /s /q %HOMEPATH%\AppData\Roaming\npm - 清理 npm 包。
    3. 运行 rmdir /s /q %HOMEPATH%\AppData\Roaming\npm-cache - 通过删除它来清理 npm 缓存。
    4. 运行 npm login --registry=https://npm.sencha.com --scope=@sencha - 重新登录到存储库。 运行 npm install -g @sencha/ext-gen 或 npm install -g @sencha/ext-react-gen

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2016-06-02
      • 1970-01-01
      • 2021-11-21
      • 1970-01-01
      • 2014-02-20
      相关资源
      最近更新 更多