node-sass

解决Cannot download "https://github.com/sass/node-sass/releases/download/...."

一笑奈何 提交于 2019-12-25 04:38:10
遇到好几次了,存一下这个命令 由于网速原因,执行npm install命令过程中,node-sass无法下载,那么可以使用淘宝镜像下载,具体命令如下: npm i node-sass --sass_binary_site=https://npm.taobao.org/mirrors/node-sass/ 来源: CSDN 作者: 水越帆 链接: https://blog.csdn.net/qq_41618510/article/details/103683308

Sass import not crawling node_modules to find appropriate package

孤者浪人 提交于 2019-12-24 01:09:39
问题 I am using bootstrap-sass. The node module is installed. I should expect I can, in any .scss file, use the below line to import into an appropriate sheet @import 'bootstrap'; My understanding is what should happen is the compiler crawls up until it finds package.json, hops into node_modules, and finds the appropriate package. Instead I am getting the below error. Error: File to import not found or unreadable: bootstrap If I replace my import with a fully qualified path as below, then

npm install时出现npm ERR!

拟墨画扇 提交于 2019-12-23 10:59:16
可能是网络的问题 1. 如何使用镜像 npm npm全称Node Package Manager,是node.js的模块依赖管理工具。由于npm的源在国外,所以国内用户使用起来各种不方便,在使用时故会导致环境配置失败。 解决办法是翻墙或者使用淘宝镜像cnpm下载; 下面整理出了一部分国内优秀的npm镜像资源,国内用户可以选择使用。 以阿里npm镜像举例: 在项目终端 或 cmd 输入: npm --registry https://registry.npm.taobao.org install express npm config set registry https://registry.npm.taobao.org 配置后可通过下面方式来验证是否成功 npm config get registry 或者是 npm info express 安装好 npm 后,在继续安装 cnpm cnpm安装配置方法 同理在项目终端 或 cmd 输入: npm install -g cnpm --registry=https://registry.npm.taobao.org 使用 cnpm install express 2. node-sass安装失败 nodejs – node-sass安装失败 安装 node-sass 的时候总是会各种不成功,nodejs – node

Webpack-simple + vue-cli with SASS - Can't compile?

旧时模样 提交于 2019-12-22 10:29:57
问题 I set up a simple project with vue-cli and webpack-simple using the default CLI settings and made sure that 'Y' was selected when asked whether I wanted to use SASS. First, folder structure pic: I created a main.scss file in the ./src/scss directory and added the following simple scss syntax to the file: $primary-color: rgb(173, 16, 16); Then, in my App.vue template, I have it like so: <style lang="scss" scoped> h1, h2 { font-weight: normal; color: $primary-color; } </style> In my main.js

npm just won't install node sass

我只是一个虾纸丫 提交于 2019-12-22 05:18:10
问题 I first encountered the issue when trying to use ionic and it needed the dependency for its templates. Then when I tried to install node-sass with npm myself the issue persisted. This is on Windows 10 Version 1703 , both nodejs 6.11.3 and nodejs 8.4.0 tried out, ended up with same result. And VPN, http proxy were tried with no luck. Basically, it's saying : Cannot download "https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-57_binding.node" when nothing is fiddled with ,it

Webpack SASS loader cannot dedupe common SCSS imports

久未见 提交于 2019-12-20 19:45:07
问题 I have the following structure: node_modules - my_component - font - scss - my_component.scss src - my_app.js - my_app.scss I'm trying to import the styles in my_component.scss . This file contains @font-face declarations with references to ../font/ . So something like: // my_component.scss @font-face { font-family: 'Helvetica Neue'; font-weight: $weight-medium; src: url('../font/font-file.eot'); } In my_app.js I'm requiring the SCSS file associated with it. So // my_app.js require('./my_app

Combine all sass files into a single file

南楼画角 提交于 2019-12-19 12:52:47
问题 Is there any option available in gulp-sass to combine sass files? For example: main.scss: $var: red; control.scss: @import 'main'; .a{ color: $var; } The combined output file should be single scss file like below $var: red; .a{ color: $var; } 回答1: Did you try something like this? gulp = require('gulp'); concat = require('gulp-concat'); // the default task gulp.task('default', function() { return gulp.src('./*.scss') .pipe(concat('all.scss')) .pipe(gulp.dest('./dist/')); }); This should

How can I get node-sass watch and live reload to work from a single NPM script?

扶醉桌前 提交于 2019-12-18 16:59:11
问题 Taking the following scripts section from a package.json : "scripts":{ "sass:watch": "npm run sass -- -w ./src/public/stylesheets -r --source-map true", "livereload": "live-reload --port 9091 ./src/**/*", "dev:watch" : "npm run sass:watch; npm run livereload" } How can I successfully get both the sass:watch and livereload tasks to run, without blocking each other, from the dev:watch task? Currently, when I run npm run dev:watch sass:watch blocks livereload . If I reorder them, the same

解决MSBUILD : error MSB3428错误

醉酒当歌 提交于 2019-12-18 11:17:28
问题: MSBUILD : error MSB3428: 未能加载 Visual C++ 组件“VCBuild.exe”。要解决此问题,1) 安装 .NET Framework 2.0 SDK;2) 安装 Microsoft Visual Studio 2005;或 3) 如果将该组件安 装到了其他位置,请将其位置添加到系统路径中。 解决方法: 一、在【.npmrc】文件中添加淘宝镜像地址:(然后再重新编译) phantomjs_cdnurl=http://cnpmjs.org/downloads sass_binary_site=https://npm.taobao.org/mirrors/node-sass/ registry=https://registry.npm.taobao.org 二、执行卸载安装: npm uninstall node-sass 三、执行重新安装: npm install node-sass(或 npm install) 来源: CSDN 作者: communal 链接: https://blog.csdn.net/yan072201/article/details/103592463

Node sass Error while doing npm install

只愿长相守 提交于 2019-12-13 05:43:53
问题 i was trying to do an npm install command, But ended up with an error related node sass. I learning react/redux from the "https://github.com/buckyroberts/React-Redux-Boilerplate" from this. and doing npm install fails. The error is attached as image. I am using windows 7, with node 6.9. any idea to solve this error? 回答1: This is likely a package that depends on native build tools. Do you have Visual Studio installed? If not, try installing it first and reboot before retrying npm install. Your