最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - How to handle 'code generator has deoptimised styling' message from gulp-babel - Stack Overflow

programmeradmin3浏览0评论

I've just employed gulp-babel to my gulp file with the following

var babel = require('gulp-babel');

return gulp.src(files.concat.js.myModule)
  .pipe(babel())
  .pipe(concat('myModule.js'))
  .pipe(gulp.dest('path/to/js'));

...and I get the following Note about deoptimising the styling in my gulp output:

NOTE: The code generator has deoptimised the styling ... as it exceeds the max of "100KB"

Is this a problem?
Should I be handling this is some way?

I've just employed gulp-babel to my gulp file with the following

var babel = require('gulp-babel');

return gulp.src(files.concat.js.myModule)
  .pipe(babel())
  .pipe(concat('myModule.js'))
  .pipe(gulp.dest('path/to/js'));

...and I get the following Note about deoptimising the styling in my gulp output:

NOTE: The code generator has deoptimised the styling ... as it exceeds the max of "100KB"

Is this a problem?
Should I be handling this is some way?

Share Improve this question edited Aug 1, 2015 at 10:39 Leonid Beschastny 51.5k10 gold badges120 silver badges123 bronze badges asked Jun 16, 2015 at 23:10 sfletchesfletche 49.7k31 gold badges108 silver badges120 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 25

Turns out the compact option is set to auto by default which removes "superfluous whitespace characters and line terminators [...] on input sizes >100KB".

If this is not what you want, you can set the compact option to false...

.pipe(babel({compact: false}))
发布评论

评论列表(0)

  1. 暂无评论