最新消息: 电脑我帮您提供丰富的电脑知识,编程学习,软件下载,win7系统下载。

角度:nodejs升级到12.x后项目无法启动

IT培训 admin 6浏览 0评论

角度:nodejs升级到12.x后项目无法启动

通过以下消息将nodejs从10.x升级到12.x后,我的Angular项目无法构建和启动:

Module build failed (from ./node_modules/sass-loader/lib/loader.js):
Error: Missing binding C:\xxx\client\node_modules\node-sass\vendor\win32-x64-72\binding.node
Node Sass could not find a binding for your current environment: Windows 64-bit with Node.js 12.x
Found bindings for the following environments:
- Windows 64-bit with Node.js 10.x
This usually happens because your environment has changed since running `npm install`.
Run `npm rebuild node-sass` to download the binding for your current environment.

我尝试了npm rebuild node-sass,但仍然无法正常工作。那是什么问题呢?

回答如下:

您可以尝试以下操作:

  1. 先删除node_modules,然后再删除npm i
  2. 卸载node-sass,然后重新安装它。

    npm uninstall node-sass npm i node-sass

角度:nodejs升级到12.x后项目无法启动

通过以下消息将nodejs从10.x升级到12.x后,我的Angular项目无法构建和启动:

Module build failed (from ./node_modules/sass-loader/lib/loader.js):
Error: Missing binding C:\xxx\client\node_modules\node-sass\vendor\win32-x64-72\binding.node
Node Sass could not find a binding for your current environment: Windows 64-bit with Node.js 12.x
Found bindings for the following environments:
- Windows 64-bit with Node.js 10.x
This usually happens because your environment has changed since running `npm install`.
Run `npm rebuild node-sass` to download the binding for your current environment.

我尝试了npm rebuild node-sass,但仍然无法正常工作。那是什么问题呢?

回答如下:

您可以尝试以下操作:

  1. 先删除node_modules,然后再删除npm i
  2. 卸载node-sass,然后重新安装它。

    npm uninstall node-sass npm i node-sass

发布评论

评论列表 (0)

  1. 暂无评论