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

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

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

        <tfoot id='ErWXq'></tfoot>
      1. 在繼續(xù)下一個(gè)任務(wù)之前使 gulp 同步寫入文件

        Making gulp write files synchronously before moving on to the next task(在繼續(xù)下一個(gè)任務(wù)之前使 gulp 同步寫入文件)

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

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

                <tbody id='on7ws'></tbody>
              <legend id='on7ws'><style id='on7ws'><dir id='on7ws'><q id='on7ws'></q></dir></style></legend>
                  <bdo id='on7ws'></bdo><ul id='on7ws'></ul>

                  <tfoot id='on7ws'></tfoot>

                  本文介紹了在繼續(xù)下一個(gè)任務(wù)之前使 gulp 同步寫入文件的處理方法,對(duì)大家解決問題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

                  問題描述

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

                  gulpfile.js

                  gulpfile.js

                  gulp.task('browser-bundle', ['react'], function() {
                  ...
                  
                  });
                  
                  
                  gulp.task('react', function(){
                    gulp.src(options.JSX_SOURCE)
                        .pipe(react())
                        .pipe(gulp.dest(options.JSX_DEST))
                  });
                  

                  如您所見,我有瀏覽器捆綁任務(wù),具體取決于反應(yīng)任務(wù).我相信這可以按預(yù)期工作,因?yàn)樵谳敵鲋形铱吹搅?

                  As you can see I have the browser-bundle task depending on the react task. I believe this works as expected because in the output I see this:

                  [gulp] Running 'react'...
                  [gulp] Finished 'react' in 3.43 ms
                  [gulp] Running 'browser-bundle'...
                  

                  然而,雖然 react 任務(wù)已經(jīng)完成,但它應(yīng)該寫入操作系統(tǒng)的文件還沒有完全到位.我注意到,如果我在瀏覽器捆綁命令中添加了一個(gè) sleep 語句,那么它會(huì)按預(yù)期工作,但這對(duì)我來說似乎有點(diǎn) hacky.

                  However, although the react task is finished, the files its supposed to write to the operating system are not quite there yet. I've notice that if I put a sleep statement in the browser bundle command then it works as expected, however this seems a little hacky to me.

                  如果我希望在文件(來自 gulp.dest)被同步寫入磁盤之前不認(rèn)為反應(yīng)任務(wù)完成,我該怎么做?

                  If I want the react task to not be considered finished until the files (from gulp.dest) have been synchronously written to disk how would I do that?

                  推薦答案

                  你需要一個(gè)return語句:

                  You need a return statement:

                  gulp.task('react', function(){
                      return gulp.src(options.JSX_SOURCE)
                          .pipe(react())
                          .pipe(gulp.dest(options.JSX_DEST))
                  });
                  

                  這樣,我所有的寫操作都在下一個(gè)任務(wù)處理之前完成.

                  With this all my write operations are done before the next task processed.

                  這篇關(guān)于在繼續(xù)下一個(gè)任務(wù)之前使 gulp 同步寫入文件的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(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 類型而未加載樣式表)
                  Visual Studio 2015 crashes when opening Javascript files(打開 Javascript 文件時(shí) Visual Studio 2015 崩潰)
                      <bdo id='IVtV4'></bdo><ul id='IVtV4'></ul>
                    • <tfoot id='IVtV4'></tfoot>
                        <tbody id='IVtV4'></tbody>
                    • <small id='IVtV4'></small><noframes id='IVtV4'>

                        <i id='IVtV4'><tr id='IVtV4'><dt id='IVtV4'><q id='IVtV4'><span id='IVtV4'><b id='IVtV4'><form id='IVtV4'><ins id='IVtV4'></ins><ul id='IVtV4'></ul><sub id='IVtV4'></sub></form><legend id='IVtV4'></legend><bdo id='IVtV4'><pre id='IVtV4'><center id='IVtV4'></center></pre></bdo></b><th id='IVtV4'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='IVtV4'><tfoot id='IVtV4'></tfoot><dl id='IVtV4'><fieldset id='IVtV4'></fieldset></dl></div>
                      1. <legend id='IVtV4'><style id='IVtV4'><dir id='IVtV4'><q id='IVtV4'></q></dir></style></legend>
                          • 主站蜘蛛池模板: 国产亚洲精品久久久久动 | 波多野结衣电影一区 | 久久成人免费观看 | 一区二区蜜桃 | 玖操| 日韩精品一区二区三区视频播放 | 亚洲成人精品 | 五月天婷婷久久 | www天天操 | 999精品网| 精品欧美一区二区三区久久久 | 毛片免费观看视频 | 欧美一区二区三区视频 | 欧美三级电影在线播放 | 亚洲国产aⅴ成人精品无吗 国产精品永久在线观看 | 国产福利在线小视频 | 日韩视频在线播放 | 午夜视频精品 | 中文字幕第三页 | 中文字幕一区二区三区四区五区 | 日本中文在线 | 91啪影院| 欧美精品综合在线 | 国产亚洲精品a | 国产综合在线视频 | 日韩成人在线一区 | 青青久草 | 日韩精品在线看 | 国产精品视频久久 | 中文天堂在线一区 | 国产一区二区欧美 | 91精品免费 | 99精品视频一区二区三区 | 午夜免费观看体验区 | 亚洲国产欧美一区 | 亚洲精品视频一区二区三区 | 精国产品一区二区三区 | 国产精品入口麻豆www | 国产一区二区三区精品久久久 | 国产一区二区在线播放 | 一呦二呦三呦国产精品 |