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

    <bdo id='Sq0eU'></bdo><ul id='Sq0eU'></ul>
<tfoot id='Sq0eU'></tfoot>

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

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

      1. <legend id='Sq0eU'><style id='Sq0eU'><dir id='Sq0eU'><q id='Sq0eU'></q></dir></style></legend>
      2. JavaScript在angular js gulp sourcemap ngannonate中用babel堆

        JavaScript heap out of memory in angular js gulp sourcemap ngannonate with babel(JavaScript在angular js gulp sourcemap ngannonate中用babel堆內存不足)

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

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

                  本文介紹了JavaScript在angular js gulp sourcemap ngannonate中用babel堆內存不足的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  限時送ChatGPT賬號..

                  我在我的 Angular JS 項目中使用 es6 語法,但是在運行 gulp build 時會拋出錯誤,在 github 上搜索,所以但有人說這是由于 gulp uglify 而導致的錯誤,而有人說這是 babel問題和其他說 ng-annonate 問題.

                  I am using es6 syntax in my angular JS project but it throws error when run gulp build, search over github and So but some saying this is error due to gulp uglify while some say this is babel issue and other say ng-annonate issue.

                  ubuntu 14.04

                  節點-v:8.4.0

                  npm -v : 5.3.0

                  babel --version : 6.26.0 (babel-core 6.26.0)

                  babel --version : 6.26.0 (babel-core 6.26.0)

                  package.json

                  {
                    "name": "Project",
                    "version": "0.0.0",
                    "dependencies": {
                      "gulp-open": "^2.0.0"
                    },
                    "scripts": {
                      "test": "gulp test"
                    },
                    "devDependencies": {
                      "babel": "^6.23.0",
                      "babel-core": "^6.25.0",
                      "babel-preset-es2015": "^6.24.1",
                      "browser-sync": "~2.9.11",
                      "browser-sync-spa": "~1.0.3",
                      "chalk": "~1.1.1",
                      "del": "~2.0.2",
                      "eslint-plugin-angular": "~0.12.0",
                      "estraverse": "~4.1.0",
                      "gulp": "~3.9.0",
                      "gulp-angular-filesort": "~1.1.1",
                      "gulp-angular-templatecache": "~1.8.0",
                      "gulp-autoprefixer": "~3.0.2",
                      "gulp-babel": "^7.0.0",
                      "gulp-clean-css": "~2.0.12",
                      "gulp-connect": "^5.0.0",
                      "gulp-eslint": "~1.0.0",
                      "gulp-filter": "~3.0.1",
                      "gulp-flatten": "~0.2.0",
                      "gulp-html-replace": "^1.6.1",
                      "gulp-htmlmin": "~2.0.0",
                      "gulp-inject": "~3.0.0",
                      "gulp-less": "~3.0.3",
                      "gulp-livereload": "^3.8.1",
                      "gulp-load-plugins": "~0.10.0",
                      "gulp-merge": "^0.1.1",
                      "gulp-ng-annotate": "~1.1.0",
                      "gulp-ng-config": "^1.3.1",
                      "gulp-nginxer": "^1.0.0",
                      "gulp-order": "^1.1.1",
                      "gulp-protractor": "~1.0.0",
                      "gulp-rename": "~1.2.2",
                      "gulp-replace": "~0.5.4",
                      "gulp-rev": "~6.0.1",
                      "gulp-rev-replace": "~0.4.2",
                      "gulp-size": "~2.0.0",
                      "gulp-sourcemaps": "~1.6.0",
                      "gulp-uglify": "~1.4.1",
                      "gulp-useref": "~1.3.0",
                      "gulp-util": "~3.0.6",
                      "gulp-war": "^0.1.4",
                      "gulp-zip": "^3.2.0",
                      "gulp.spritesmith": "^6.3.0",
                      "http-proxy-middleware": "~0.9.0",
                      "klaw-sync": "^1.1.2",
                      "lodash": "~4.0.0",
                      "main-bower-files": "~2.9.0",
                      "merge-stream": "^1.0.1",
                      "path": "^0.12.7",
                      "phantomjs": "~1.9.18",
                      "uglify-save-license": "~0.4.1",
                      "wiredep": "~2.2.2"
                    },
                    "engines": {
                      "node": ">=0.10.0"
                    }
                  }
                  

                  gulp/.babelrc

                  {
                      "presets": ["es2015"],
                      "plugins": ["syntax-decorators", "ng-annotate"] // this line is added after seeking for solution
                  }
                  

                  gulp/build.js相關代碼

                  .pipe(jsFilter)
                      .pipe($.sourcemaps.init())
                      .pipe($.babel({"presets": [ ["es2015", { "modules": false} ] ], compact: false}))
                      .pipe($.ngAnnotate())
                      .pipe($.uglify({
                        preserveComments: $.uglifySaveLicense
                      })).on('error', conf.errorHandler('Uglify'))
                      .pipe($.sourcemaps.write('.'))
                      .pipe(jsFilter.restore)
                  

                  還嘗試了 .pipe(uglify({compress: {sequences: false, join_vars: false}})) 根據 這個解決方案.但無濟于事

                  also tried .pipe(uglify({compress: {sequences: false, join_vars: false}})) as per this solution . but does not help

                  這里是執行gulp build

                  <--- Last few GCs --->
                  
                  [15435:0x303a4b0]   401581 ms: Mark-sweep 1399.9 (1459.1) -> 1399.9 (1459.1) MB, 3617.4 / 0.0 ms  allocation failure GC in old space requested [15435:0x303a4b0]   405886 ms: Mark-sweep 1399.9 (1459.1) ->
                  1399.9 (1459.1) MB, 4101.3 / 0.0 ms  allocation failure GC in old space requested [15435:0x303a4b0]   409592 ms: Mark-sweep 1399.9 (1459.1) -> 1399.9 (1459.1) MB, 3705.3 / 0.0 ms  last resort  [15435:0x303a4b0]   413501 ms: Mark-sweep 1399.9 (1459.1) -> 1399.9 (1459.1) MB, 3908.9 / 0.0 ms  last resort 
                  
                  
                  <--- JS stacktrace --->
                  
                  ==== JS stack trace =========================================
                  
                  Security context: 0x1d10fec9cef1 <JSObject>
                      1: /* anonymous */ [/opt/project/path/node_modules/vinyl-sourcemaps-apply/node_modules/source-map/lib/source-map/source-map-generator.js:~52] [pc=0x355474d0ca02](this=0xc4a489090d9 <JSGlobal Object>,mapping=0xbf1d8defe31 <Object map = 0xa04f5db0ae9>)
                      2: arguments adaptor frame: 3->1
                      3: forEach(this=0x11ebaae17be9 <JSArray[466526]>)
                      5: SourceMapConsumer_ea...
                  
                  FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory  1: node::Abort() [gulp]  2: 0x128fdfc [gulp]  3: v8::Utils::ReportOOMFailure(char const*, bool) [gulp]  4: v8::internal::V8::FatalProcessOutOfMemory(char const*, bool) [gulp]  5: v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationSpace) [gulp]  6: v8::internal::Runtime_AllocateInTargetSpace(int, v8::internal::Object**, v8::internal::Isolate*) [gulp]  7: 0x3554749840dd Aborted
                  

                  推薦答案

                  主要原因是 uglify 插件無法使用 es6 語法,所以這樣做

                  The main cause was uglify plugin which does not work with es6 syntax so did this

                  1. npm install babel-cli -g
                  2. bower install gulp-uglify-es --save-dev

                  gulp/build.js

                  var uglify = require('gulp-uglify-es').default;

                  然后在下面寫到 gulp 任務

                  and wrire belowcinside gulp task

                   .pipe($.sourcemaps.init())
                      .pipe($.babel({"presets": [ ["es2015", { "modules": false} ] ], compact: false}))
                      .pipe($.ngAnnotate())
                      .pipe(uglify()).on('error', conf.errorHandler('Uglify'))
                      .pipe($.sourcemaps.write('.'))
                  

                  更新package.json

                  {
                    "name": "Project",
                    "version": "0.0.0",
                    "dependencies": {
                      "gulp-open": "^2.0.0"
                    },
                    "scripts": {
                      "test": "gulp test"
                    },
                    "devDependencies": {
                      "babel": "^6.23.0",
                      "babel-core": "^6.25.0",
                      "babel-preset-es2015": "^6.24.1",
                      "babel-preset-minify": "^0.2.0",
                      "chalk": "~1.1.1",
                      "del": "~2.0.2",
                      "eslint-plugin-angular": "~0.12.0",
                      "estraverse": "~4.1.0",
                      "gulp": "~3.9.0",
                      "gulp-angular-filesort": "~1.1.1",
                      "gulp-angular-templatecache": "~1.8.0",
                      "gulp-autoprefixer": "~3.0.2",
                      "gulp-babel": "^7.0.0",
                      "gulp-babel-minify": "^0.2.0",
                      "gulp-clean-css": "~2.0.12",
                      "gulp-connect": "^5.0.0",
                      "gulp-eslint": "~1.0.0",
                      "gulp-filter": "~3.0.1",
                      "gulp-flatten": "~0.2.0",
                      "gulp-html-replace": "^1.6.1",
                      "gulp-htmlmin": "~2.0.0",
                      "gulp-inject": "~3.0.0",
                      "gulp-less": "~3.0.3",
                      "gulp-livereload": "^3.8.1",
                      "gulp-load-plugins": "~0.10.0",
                      "gulp-merge": "^0.1.1",
                      "gulp-ng-annotate": "~1.1.0",
                      "gulp-ng-config": "^1.3.1",
                      "gulp-order": "^1.1.1",
                      "gulp-protractor": "~1.0.0",
                      "gulp-rename": "~1.2.2",
                      "gulp-replace": "~0.5.4",
                      "gulp-rev": "~6.0.1",
                      "gulp-rev-replace": "~0.4.2",
                      "gulp-size": "~2.0.0",
                      "gulp-sourcemaps": "~1.6.0",
                      "gulp-uglify": "~1.4.1",
                      "gulp-uglify-es": "^0.1.3",
                      "gulp-useref": "~1.3.0",
                      "gulp-util": "~3.0.6",
                      "gulp-war": "^0.1.4",
                      "gulp-zip": "^3.2.0",
                      "gulp.spritesmith": "^6.3.0",
                      "http-proxy-middleware": "~0.9.0",
                      "klaw-sync": "^1.1.2",
                      "lodash": "~4.0.0",
                      "main-bower-files": "~2.9.0",
                      "merge-stream": "^1.0.1",
                      "path": "^0.12.7",
                      "phantomjs": "~1.9.18",
                      "uglify-es": "^3.0.28",
                      "uglify-save-license": "~0.4.1",
                      "wiredep": "~2.2.2"
                    },
                    "engines": {
                      "node": ">=0.10.0"
                    }
                  }
                  

                  這篇關于JavaScript在angular js gulp sourcemap ngannonate中用babel堆內存不足的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

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

                  相關文檔推薦

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

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

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

                            主站蜘蛛池模板: 国产一区二区三区在线观看免费 | 国产资源网 | 欧美日韩一区二区三区在线观看 | 亚洲天堂中文字幕 | 亚洲在线高清 | 99精品视频免费在线观看 | 久久综合一区二区三区 | 欧美九九九 | 国产亚洲精品精品国产亚洲综合 | 国产一区二区三区在线 | 婷婷成人在线 | v片网站 | 国产精品高潮呻吟久久av黑人 | 欧美www在线观看 | 日本精品裸体写真集在线观看 | 亚洲在线一区二区 | 久久99国产精品久久99果冻传媒 | 免费一级欧美在线观看视频 | 中国美女撒尿txxxxx视频 | 看特级黄色片 | 成人在线视频网 | 亚洲精品九九 | 国产一级片免费在线观看 | 成年人黄色小视频 | 亚洲一区在线免费观看 | 国产福利视频网站 | 国产成人一区二区三区 | 欧美日韩免费视频 | 欧美日韩国产一区二区 | 色偷偷888欧美精品久久久 | 全部免费毛片在线播放网站 | 成人国产精品色哟哟 | 日韩精品在线看 | 亚洲一区影院 | 国产成人在线一区 | 中文字幕一区二区三区四区五区 | 欧美亚洲国产精品 | 日本三级做a全过程在线观看 | 亚洲成人精品国产 | 中文字幕乱码一区二区三区 | 日日夜夜精品视频 |