I'm having a problem with compiling my CSS, when I make a change in my SASS file it doesn't change the final file, just after trying more than once. var gulp = require('gulp'); var sass = require('gulp-sass'); var rename = require('gulp-rename'); var postcss = require('gulp-postcss'); var autoprefixer = require('autoprefixer'); var cssnano = require('cssnano');
我在编译我的CSS时遇到了问题,当我在SASS文件中进行更改时,它不会更改最终文件,只需尝试多次。 var gulp = require('gulp'); var sass = require('gulp-sass'); var rename = require('gulp-rename'); var postcss = require('gulp-postcss'); var autoprefixer = require('autoprefixer'); var cssnano = require('cssnano'); var concat = require('gulp-concat'); var uglify = require
I've made a gulp task for browserify with babelify in my Angular project, which I'm developing in WebStorm. First of all, I should say, that this code does work perfectly . My browserify bundle be like: const appBundle = browserify({ entries: config.client.src.appModule, // main angular app file debug: TRUE, packageCache: {}, cache: {} }).transform(babelify, {only: '.
我在我的Angular项目中使用babelify进行了browserify项目,我在WebStorm中开发了一个gulp任务。 首先,我应该说, 这段代码确实工作得很好 。 我的browserify包如下所示: const appBundle = browserify({ entries: config.client.src.appModule, // main angular app file debug: TRUE, packageCache: {}, cache: {} }).transform(babelify, {only: './src/client'}).on('log', gutil.log); 我的gulp.tas
I have a project with a few relatively disjoint pages, each including their own entry point script. These scripts require a number of others using commonjs syntax, and need to be transformed by 6to5 and bundled by browserify. I would like to set up a gulp task that captures all the files matching a pattern and passes them on to the bundler, but I'm not sure how to pass files from gulp.src
我有一个项目有一些相对不相关的页面,每个页面都包含他们自己的入口点脚本。 这些脚本require其他许多使用commonjs语法的脚本,并且需要通过6to5进行转换,并通过browserify进行捆绑。 我想建立一个吞噬任务,捕获所有匹配模式的文件,并将它们传递给捆绑器,但我不知道如何将文件从gulp.src传递到gulp.src browserify(filename) 。 我的gulpfile看起来像: var gulp = require("gulp"); var browserify = require("browse
I am using Gulp as my task runner and browserify to bundle my CommonJs modules. I have noticed that running my browserify task is quite slow, it takes around 2 - 3 seconds, and all I have is React and a few very small components I have built for development. Is there a way to speed up the task, or do I have any noticeable problems in my task? gulp.task('browserify', function() { var bundle
我使用Gulp作为我的任务跑步者,并且通过browserify来捆绑我的CommonJs模块。 我注意到,运行我的browserify任务非常慢,大约需要2 - 3秒,而我所拥有的就是React和我为开发构建的一些非常小的组件。 有没有加快任务的方法,或者我的任务中有什么明显的问题? gulp.task('browserify', function() { var bundler = browserify({ entries: ['./main.js'], // Only need initial file transform: [reactify], // C
I am trying to use both gulp-watch and gulp-inject to build my Node Web app. However, it seems that the build step involving gulp-inject won't work once gulp-watch gets involved. Seemingly, the reason is that the watch stream never ends and gulp-inject doesn't know when to start. My gulpfile looks as follows: var gulp = require('gulp') var inject = require('gulp-inject') var sass =
我正尝试使用gulp-watch和gulp-inject构建我的Node Web应用程序。 但是,一旦吞咽手表参与其中,似乎涉及吞咽注射的构建步骤将不起作用。 表面watch ,原因在于watch流不会结束,吞咽注射不知道什么时候开始。 我的大文件如下所示: var gulp = require('gulp') var inject = require('gulp-inject') var sass = require('gulp-sass') var path = require('path') var bower = require('gulp-bower') var bowerFiles = requ
I want to have a gulpfile that first transforms my es6 code to es5 and save it to one dir, then browserify it (on every file, not just an entry file) and save it to another dir, lastly I want to minify it and put it in the browserified folder as .min.js files. Here's a diagram of what the result should look like: src/ es6/ index.js mod.js es5/ index.js mod.js es5-brows
我想要一个gulp文件,它首先将我的es6代码转换为es5并将其保存到一个目录,然后对其进行浏览(在每个文件上,而不仅仅是一个条目文件)并将其保存到另一个目录,最后我想缩小它并将其放入它在browserified文件夹中作为.min.js文件。 下面是结果应该是什么样子的图表: src/ es6/ index.js mod.js es5/ index.js mod.js es5-browser/ index.js index.min.js mod.js mod.min.js 这是我迄
I started working on a chrome extension. So far I setup the project using gulp to watch the folder containing the code for background, popup, content and a few other pages. Each component shares some some code with the others. The problem is that every time I edit a file watchify will trigger a full rebuild. I have tried to limit the browserify process to only handle the files that have cha
我开始研究Chrome扩展。 到目前为止,我使用gulp来设置项目来观察包含背景,弹出窗口,内容和其他几页的代码的文件夹。 每个组件与其他组件共享一些代码。 问题是,每次我编辑一个文件watchify都会触发完整的重建。 我试图限制browserify进程只处理已更改的文件。 它对根脚本(popup.js,background.js,content.js)非常有效......但不幸的是,我无法跟踪依赖项(根脚本或它们的依赖项需要的文件),并且此策略在依赖项
I'm using gulp with browserify. I have a bundle() function which is like this: function bundle(script) { return browserify( get_browserify_config(script) ) .bundle() .on('error', function(err){ notifyError('error while bundling ' + script ); console.log('-- error while bundling ' + script + ' --'); errorLog(err); })
我正在用browserify使用gulp。 我有一个bundle()函数,就像这样: function bundle(script) { return browserify( get_browserify_config(script) ) .bundle() .on('error', function(err){ notifyError('error while bundling ' + script ); console.log('-- error while bundling ' + script + ' --'); errorLog(err); }) .pipe(source(sc
I have a purely web-based app (ie no Node server) and I want to be able to bundle all my JS files and CSS files for each page of the web app. I was using Gulp to simply minify and concat my JS and CSS files into one bundle, but found that the order in which I supplied the files was then spewed out randomly (unacceptable if you ask me...). I tried gulp-order and other stream ordering modules wi
我有一个纯粹基于Web的应用程序(即无节点服务器),我希望能够为Web应用程序的每个页面绑定我所有的JS文件和CSS文件。 我正在使用Gulp来简单地将我的JS和CSS文件缩小并连接成一个包,但是发现我提供这些文件的顺序是随机发出的(如果你问我......就不可接受)。 我尝试了更多随机结果的gulp-order和其他流排序模块。 我想尝试browserify但我被困在两件事 使用module.exports时,我需要使用module.exports吗? 想想我的
I'm new to Browserify (and Javascript build systems in general) and have reached a point where I am thoroughly confused. I have Gulp setup to do my builds, which has always worked fine, and lately I've been using Browserify to bundle -- mostly so I can separate my code into separate files and require() them where they need to be. My issue is, I have a folder with a bunch of small modu
我是Browserify(和一般的Javascript构建系统)的新手,并且已经达到了让我感到困惑的地步。 我有Gulp安装程序来执行我的构建,这一直运行良好,最近我一直在使用Browserify进行捆绑 - 最主要的是我可以将我的代码分离为单独的文件,并且require()它们放在需要的地方。 我的问题是,我有一个文件夹,需要在另一个模块中需要一些小模块,我试图避免硬编码所有模块的名称。 有没有办法做到所有文件的要求? 我试过使用Bulki