命令行執行npm install報錯以下:css
D:\frontend\viewsdev>npm install npm ERR! code EINTEGRITY npm ERR! sha512-8qtu6VYSXUExVPx6H8s8+OhQo0UQP7ogAoOa2bOPCvnhlpaGVYf3yh45WNa7PhhdWSOGQW3DdblqMX8UJ7Cu6g== integrity checksum failed when using sha512: wanted sha512-8qtu6VYSXUExVPx6H8s8+OhQo0UQP7ogAoOa2bOPCvnhlpaGVYf3yh45WNa7PhhdWSOGQW3DdblqMX8UJ7Cu6g== but got sha512-OvgW+e/pBS2QuX5CTDaaE+DM62t8mMk+IJfcpE3Zv1DC03DwoOKcyqRHlA+lkXWahSOPmvYZJSEDUKX0nOeLDw==. (4954746 bytes)
後來發現是npm版本問題,須要更新至最新版本:html
D:\frontend\viewsdev>npm install -g npm C:\Users\wulf\AppData\Roaming\npm\npx -> C:\Users\wulf\AppData\Roaming\npm\node_modules\npm\bin\npx-cli.js C:\Users\wulf\AppData\Roaming\npm\npm -> C:\Users\wulf\AppData\Roaming\npm\node_modules\npm\bin\npm-cli.js + npm@6.3.0 added 396 packages in 45.85s
從新install成功:node
D:\frontend\viewsdev>npm install > wlf@1.0.0 preinstall D:\frontend\viewsdev > npm install ./local_modules/my-htmlone ./local_modules/my-url-loader npm WARN deprecated gulp-util@3.0.8: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5 npm WARN deprecated CSSselect@0.4.1: the module is now available as 'css-select' npm WARN deprecated CSSwhat@0.4.7: the module is now available as 'css-what' npm WARN url-loader@0.5.9 requires a peer of file-loader@* but none is installed. You must install peer dependencies yourself. npm WARN wlf@1.0.0 No repository field. + my-htmlone@0.1.9 + my-url-loader@0.5.7 updated 2 packages and audited 131 packages in 12.198s found 3 vulnerabilities (2 low, 1 moderate) run `npm audit fix` to fix them, or `npm audit` for details npm WARN deprecated babel-preset-es2015@6.24.1: 🙌 Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update! npm WARN deprecated gulp-webpack@1.5.0: Has been renamed to https://www.npmjs.com/package/webpack-stream npm WARN deprecated gulp-util@2.2.20: gulp-util is deprecated - replace it, following the guidelines at https://medium.com/gulpjs/gulp-util-ca3b1f9f9ac5 npm WARN deprecated graceful-fs@2.0.3: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js npm WARN deprecated react-tools@0.13.3: react-tools is deprecated. For more information, visit https://fb.me/react-tools-deprecated npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js npm WARN deprecated minimatch@2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools. npm WARN deprecated minimatch@0.2.14: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue npm WARN deprecated graceful-fs@1.2.3: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js > node-sass@4.9.2 install D:\frontend\viewsdev\node_modules\node-sass > node scripts/install.js Downloading binary from https://github.com/sass/node-sass/releases/download/v4.9.2/win32-x64-57_binding.node Download complete ] - : Binary saved to D:\frontend\viewsdev\node_modules\node-sass\vendor\win32-x64-57\binding.node Caching binary to C:\Users\wulf\AppData\Roaming\npm-cache\node-sass\4.9.2\win32-x64-57_binding.node > node-sass@4.9.2 postinstall D:\frontend\viewsdev\node_modules\node-sass > node scripts/build.js Binary found at D:\frontend\viewsdev\node_modules\node-sass\vendor\win32-x64-57\binding.node Testing binary Binary is fine npm WARN slick-carousel@1.8.1 requires a peer of jquery@>=1.8.0 but none is installed. You must install peer dependencies yourself. npm WARN sass-loader@3.2.3 requires a peer of node-sass@^3.4.2 but none is installed. You must install peer dependencies yourself. npm WARN wlf@1.0.0 No repository field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}) added 1243 packages from 760 contributors and audited 9576 packages in 186.808s found 22 vulnerabilities (8 low, 10 moderate, 4 high) run `npm audit fix` to fix them, or `npm audit` for details