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

      <bdo id='86pgR'></bdo><ul id='86pgR'></ul>

    <small id='86pgR'></small><noframes id='86pgR'>

    1. <legend id='86pgR'><style id='86pgR'><dir id='86pgR'><q id='86pgR'></q></dir></style></legend>
    2. <tfoot id='86pgR'></tfoot>

      <i id='86pgR'><tr id='86pgR'><dt id='86pgR'><q id='86pgR'><span id='86pgR'><b id='86pgR'><form id='86pgR'><ins id='86pgR'></ins><ul id='86pgR'></ul><sub id='86pgR'></sub></form><legend id='86pgR'></legend><bdo id='86pgR'><pre id='86pgR'><center id='86pgR'></center></pre></bdo></b><th id='86pgR'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='86pgR'><tfoot id='86pgR'></tfoot><dl id='86pgR'><fieldset id='86pgR'></fieldset></dl></div>
    3. 當(dāng) gulp-jshint 失敗時(shí),無法使 gulp-notify 彈出錯(cuò)誤消

      Cant make gulp-notify to pop up a error message when gulp-jshint fail(當(dāng) gulp-jshint 失敗時(shí),無法使 gulp-notify 彈出錯(cuò)誤消息)

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

              <legend id='kpgkX'><style id='kpgkX'><dir id='kpgkX'><q id='kpgkX'></q></dir></style></legend>
            • <small id='kpgkX'></small><noframes id='kpgkX'>

                <tbody id='kpgkX'></tbody>
                <bdo id='kpgkX'></bdo><ul id='kpgkX'></ul>
                本文介紹了當(dāng) gulp-jshint 失敗時(shí),無法使 gulp-notify 彈出錯(cuò)誤消息的處理方法,對大家解決問題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

                問題描述

                限時(shí)送ChatGPT賬號..

                所以,我們整天都在研究新的 FE 工作流程,主要想法是通過觀察者運(yùn)行一些任務(wù),我們將擁有我們的 IDE 和一個(gè)窗口,每次發(fā)生變化時(shí)都會刷新瀏覽器(scss、js, html 等).

                So, was the whole day working on our new FE workflow, the main idea is to run a few tasks through a watcher, we will have our IDE's and a window with the browsers getting refreshed each time something change (scss, js, html, etc).

                因此,如果一切順利,我們將什么也看不到:瀏覽器將重新加載,我們將繼續(xù)工作.

                So, we wont see nothing if all went good: the browser will get reload and we will keep working.

                但是,我們想使用 gulp notify 來處理錯(cuò)誤,所以萬一我們有問題,會彈出通知程序,此時(shí)您可以檢查控制臺并查看錯(cuò)誤.

                But, we want to use gulp notify for errors, so in case we have something wrong, the notifier pop up will appear, and at that point, you can check the console and see the error.

                失敗時(shí)的 sass 任務(wù)示例:

                Example for our sass task when fail:

                對于我們的樣式任務(wù),一切正常,但我無法為 JS 文件完成此操作.

                For our styles tasks, everything works fine, but Im not able to accomplish this for JS files.

                主要是,我不能讓 gulp-jshint 像我想要的那樣工作.

                Mainly, I cant make gulp-jshint works as I want.

                這將是這樣的:你保存你的 js 文件,如果失敗,彈出窗口,當(dāng)你看到這個(gè)時(shí),你進(jìn)入控制臺,你會看到 jshint-stylish 的輸出.

                Which will be like this: you save your js file, if it fails, the popup appear and when you see this, you go to the console and you see the output of jshint-stylish.

                有人可以幫我嗎?

                這是我的(非工作)解決方案:

                This is my (non working) solution:

                gulp.task( 'js-hint', function() {
                    return gulp.src( config.source )
                        .pipe( plumber() )
                        .pipe( jshint( config.jsHintRules ) )
                        .pipe( jshint.reporter( 'jshint-stylish' ) )
                        .on('error', notify.onError( { message: 'JS hint fail' } ) );
                });
                

                顯然,我的概念有問題,所以,有人能幫我指明正確的方向嗎?

                Obviously, I have a problem with concepts, so, will somebody can please put me on the right direction ?

                請注意,我只想一直發(fā)出相同的消息JS提示失敗"

                Note that I just want to emit the same message all the time "JS hint fail"

                然后,控制臺(感謝 jshint-stylish)將為我們提供更多信息.

                Then, the console (thanks to jshint-stylish) will gave us more info.

                此外,這將在一個(gè)觀察者身上.JS提示通過后,會執(zhí)行更多的任務(wù),比如borwserify,所以重要的是如果它停止了,等待"直到我完成修復(fù)然后繼續(xù).

                Also, this will be on a watcher. After JS hint pass, will execute more tasks, like borwserify, so its important that if its stop, "wait" till I finish fixing it and then keep going.

                謝謝!

                PS,我正在使用:

                吞咽 3.8.10吞咽-jshint 1.8.6吞咽通知 2.0.1

                gulp 3.8.10 gulp-jshint 1.8.6 gulp-notify 2.0.1

                通過 OSX 10.9.4

                Over a OSX 10.9.4

                推薦答案

                gulp 中的 error 事件僅在流中發(fā)生錯(cuò)誤時(shí)觸發(fā).

                The error event in gulp only fires when an error in the stream occurs.

                要將錯(cuò)誤報(bào)告器添加到 gulp-jshint 將其傳遞給 fail 報(bào)告器:

                To add an error reporter to gulp-jshint pass it through the fail reporter:

                 gulp.task('js-hint', function() {
                      return gulp.src(config.source)
                        .pipe(plumber())
                        .pipe(jshint( config.jsHintRules))
                        .pipe(jshint.reporter('jshint-stylish'))
                        .pipe(jshint.reporter('fail'))
                        .on('error', notify.onError({ message: 'JS hint fail'}));
                  });
                

                這篇關(guān)于當(dāng) gulp-jshint 失敗時(shí),無法使 gulp-notify 彈出錯(cuò)誤消息的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請聯(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 崩潰)

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

                  <tfoot id='Vtn4O'></tfoot>

                      <i id='Vtn4O'><tr id='Vtn4O'><dt id='Vtn4O'><q id='Vtn4O'><span id='Vtn4O'><b id='Vtn4O'><form id='Vtn4O'><ins id='Vtn4O'></ins><ul id='Vtn4O'></ul><sub id='Vtn4O'></sub></form><legend id='Vtn4O'></legend><bdo id='Vtn4O'><pre id='Vtn4O'><center id='Vtn4O'></center></pre></bdo></b><th id='Vtn4O'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='Vtn4O'><tfoot id='Vtn4O'></tfoot><dl id='Vtn4O'><fieldset id='Vtn4O'></fieldset></dl></div>
                        <tbody id='Vtn4O'></tbody>
                    1. <legend id='Vtn4O'><style id='Vtn4O'><dir id='Vtn4O'><q id='Vtn4O'></q></dir></style></legend>
                      • <bdo id='Vtn4O'></bdo><ul id='Vtn4O'></ul>
                          主站蜘蛛池模板: 国产美女在线免费观看 | 天天视频一区二区三区 | 久久久网 | 国产精品69毛片高清亚洲 | 99精品国自产在线 | av在线免费播放 | wwwxxx日本在线观看 | 精品久久中文 | 久久国产精品99久久久久久丝袜 | 欧美精品一区二区三区蜜桃视频 | 午夜视频一区二区三区 | 精品一区二区三区在线播放 | 青青久草 | 国产视频精品视频 | 午夜av成人 | www.夜夜骑| 日韩伦理一区二区三区 | 尹人av | 国产精品一区二区av | 在线观看一区 | 中国一级特黄真人毛片 | 国产精品福利一区二区三区 | 亚洲精品一区国产精品 | 中文字幕亚洲一区 | 黄色网址在线免费观看 | 黄色国产在线播放 | www.久久久久久久久 | 羞羞网站免费 | 中文字幕一级 | 亚洲日韩第一页 | 黑人精品欧美一区二区蜜桃 | 成人在线一区二区三区 | 日韩精品一区二区三区中文字幕 | 久草资源在线 | 亚洲精品久久久久久一区二区 | 日本激情视频在线播放 | 成人综合在线视频 | 中文字幕高清av | 久久99精品久久久久久国产越南 | 欧美一区二区三区久久精品 | 91视频免费 |