久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    1. <legend id='tYzKJ'><style id='tYzKJ'><dir id='tYzKJ'><q id='tYzKJ'></q></dir></style></legend>

      <small id='tYzKJ'></small><noframes id='tYzKJ'>

      <tfoot id='tYzKJ'></tfoot>
        <bdo id='tYzKJ'></bdo><ul id='tYzKJ'></ul>
      1. <i id='tYzKJ'><tr id='tYzKJ'><dt id='tYzKJ'><q id='tYzKJ'><span id='tYzKJ'><b id='tYzKJ'><form id='tYzKJ'><ins id='tYzKJ'></ins><ul id='tYzKJ'></ul><sub id='tYzKJ'></sub></form><legend id='tYzKJ'></legend><bdo id='tYzKJ'><pre id='tYzKJ'><center id='tYzKJ'></center></pre></bdo></b><th id='tYzKJ'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='tYzKJ'><tfoot id='tYzKJ'></tfoot><dl id='tYzKJ'><fieldset id='tYzKJ'></fieldset></dl></div>

        如何使用 gulp-browserify 觀看多個(gè)文件但只處理一個(gè)

        How do I watch multiple files with gulp-browserify but process only one?(如何使用 gulp-browserify 觀看多個(gè)文件但只處理一個(gè)文件?)

          <small id='jGvtW'></small><noframes id='jGvtW'>

          <legend id='jGvtW'><style id='jGvtW'><dir id='jGvtW'><q id='jGvtW'></q></dir></style></legend>
              <tbody id='jGvtW'></tbody>
            <tfoot id='jGvtW'></tfoot>

              <bdo id='jGvtW'></bdo><ul id='jGvtW'></ul>
                  <i id='jGvtW'><tr id='jGvtW'><dt id='jGvtW'><q id='jGvtW'><span id='jGvtW'><b id='jGvtW'><form id='jGvtW'><ins id='jGvtW'></ins><ul id='jGvtW'></ul><sub id='jGvtW'></sub></form><legend id='jGvtW'></legend><bdo id='jGvtW'><pre id='jGvtW'><center id='jGvtW'></center></pre></bdo></b><th id='jGvtW'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='jGvtW'><tfoot id='jGvtW'></tfoot><dl id='jGvtW'><fieldset id='jGvtW'></fieldset></dl></div>
                • 本文介紹了如何使用 gulp-browserify 觀看多個(gè)文件但只處理一個(gè)文件?的處理方法,對(duì)大家解決問(wèn)題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧!

                  問(wèn)題描述

                  限時(shí)送ChatGPT賬號(hào)..

                  我正在嘗試連接 gulp-browserifygulp-watch 每次源文件更改.但是,gulp-browserify 需要一個(gè)單一的編譯入口點(diǎn)(例如 src/js/app.js)并自行獲取每個(gè)依賴(lài)項(xiàng):

                  I'm trying to wire up gulp-browserify and gulp-watch to rebuild my bundle each time a source file changes. However, gulp-browserify requires a single entry point for the compilation (e.g. src/js/app.js) and fetches every dependency itself:

                  gulp.src('src/js/app.js')
                      .pipe(browserify())
                      .pipe(gulp.dest('dist'))
                  

                  但是,使用 gulp-watch 無(wú)法在每次更改時(shí)重建,因?yàn)橹槐O(jiān)視入口點(diǎn)文件.我真正需要的是可以查看多個(gè)文件,然后只處理入口點(diǎn)文件(查找 replaceEverythingWithEntryPointFile):

                  However, with gulp-watch this fails to rebuild on every change because only the entry point file is being watched. What I actually need is a possibility to watch multiple files and then process only the entry point file (look for replaceEverythingWithEntryPointFile):

                  gulp.src("src/**/*.js")
                      .pipe(watch())
                      .pipe(replaceEverythingWithEntryPointFile()) // <- This is what I need
                      .pipe(browserify())
                      .pipe(gulp.dest("dist"));
                  

                  所以問(wèn)題是:如何將 gulp-browserify 指向入口點(diǎn)文件并在任何源文件的更改時(shí)觸發(fā)重建?如果解決方案包括限制會(huì)很好:啟動(dòng)時(shí),每個(gè)源文件都被設(shè)置為觀看,因此我們的入口點(diǎn)文件將通過(guò)管道傳輸?shù)?gulp-browserify 與文件一樣多,這是不必要的.

                  So the question is: how can I point gulp-browserify to the entry point file and trigger rebuild on a change in any source file? Would be nice if the solution included throttling: when starting up, every source file is being set up for watching and thus our entry point file would be piped to gulp-browserify as many times as there are files, which is unnecessary.

                  推薦答案

                  只要調(diào)用一個(gè)正常的文件更改任務(wù),像這樣:

                  Just call a normal task on file change, like this:

                  gulp.task("build-js", function() {
                      return gulp.src('src/js/app.js')
                          .pipe(browserify())
                          .pipe(gulp.dest('dist'))
                  });
                  
                  gulp.task("watch", function() {
                      // calls "build-js" whenever anything changes
                      gulp.watch("src/**/*.js", ["build-js"]);
                  });
                  

                  如果你想使用 gulp-watch(因?yàn)樗梢圆檎倚挛募?,那么你需要這樣做:

                  If you want to use gulp-watch (because it can look for new files), then you need to do something like this:

                  gulp.task("watch", function() {
                      watch({glob: "src/**/*.js"}, function() {
                          gulp.start("build-js");
                      });
                  });
                  

                  使用 gulp-watch 還具有批處理操作的好處,因此如果您一次修改多個(gè)文件,您將不會(huì)連續(xù)獲得一堆構(gòu)建.

                  Using gulp-watch also has the benefit of batching operations, so if you modify several files at once, you won't get a bunch of builds in a row.

                  這篇關(guān)于如何使用 gulp-browserify 觀看多個(gè)文件但只處理一個(gè)文件?的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來(lái)源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問(wèn)題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  Browserify, Babel 6, Gulp - Unexpected token on spread operator(Browserify,Babel 6,Gulp - 傳播運(yùn)算符上的意外令牌)
                  Is it possible to pass a flag to Gulp to have it run tasks in different ways?(是否可以將標(biāo)志傳遞給 Gulp 以使其以不同的方式運(yùn)行任務(wù)?)
                  Why do we need to install gulp globally and locally?(為什么我們需要在全局和本地安裝 gulp?)
                  How to run Gulp tasks sequentially one after the other(如何一個(gè)接一個(gè)地依次運(yùn)行 Gulp 任務(wù))
                  Stylesheet not loaded because of MIME-type(由于 MIME 類(lèi)型而未加載樣式表)
                  Visual Studio 2015 crashes when opening Javascript files(打開(kāi) Javascript 文件時(shí) Visual Studio 2015 崩潰)
                  • <bdo id='LTh7o'></bdo><ul id='LTh7o'></ul>
                  • <legend id='LTh7o'><style id='LTh7o'><dir id='LTh7o'><q id='LTh7o'></q></dir></style></legend><tfoot id='LTh7o'></tfoot>
                      <tbody id='LTh7o'></tbody>

                    • <small id='LTh7o'></small><noframes id='LTh7o'>

                      <i id='LTh7o'><tr id='LTh7o'><dt id='LTh7o'><q id='LTh7o'><span id='LTh7o'><b id='LTh7o'><form id='LTh7o'><ins id='LTh7o'></ins><ul id='LTh7o'></ul><sub id='LTh7o'></sub></form><legend id='LTh7o'></legend><bdo id='LTh7o'><pre id='LTh7o'><center id='LTh7o'></center></pre></bdo></b><th id='LTh7o'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='LTh7o'><tfoot id='LTh7o'></tfoot><dl id='LTh7o'><fieldset id='LTh7o'></fieldset></dl></div>

                            主站蜘蛛池模板: 中文字幕在线观 | 中文字幕的av | 一区二区三区在线播放 | 99久久久无码国产精品 | 日韩一二区在线观看 | 久久精品 | 在线成人免费视频 | 免费观看www | 欧美黄色一区 | 精品亚洲一区二区 | 欧美综合国产精品久久丁香 | 国产一区二区视频免费在线观看 | 狠狠躁18三区二区一区 | 国产成人精品一区二区三区在线 | 日韩中文电影 | 91麻豆产精品久久久久久 | 雨宫琴音一区二区在线 | 久久精品视频免费看 | 欧美激情久久久 | 久久综合久久综合久久综合 | 久久午夜剧场 | 电影午夜精品一区二区三区 | 亚洲高清av在线 | 欧美黄 片免费观看 | 日韩视频在线一区 | 伊人手机在线视频 | 美日韩精品 | 日韩激情在线 | 久久久久久久电影 | www.青青草 | 亚洲欧美一区二区三区视频 | 激情91 | 国产精品a久久久久 | 亚洲成人精品 | 久久一二 | 色综合九九| 男女羞羞视频在线看 | 欧美国产亚洲一区二区 | 欧美一级视频在线观看 | 在线成人免费视频 | 一区二区三区四区国产 |