Skip to content

Commit a5e2fe6

Browse files
author
Travis CI
committed
Travis Build - f744f90
[skip ci]
1 parent f744f90 commit a5e2fe6

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

dist/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@ var WebpackObfuscator = (function () {
1515
}
1616
WebpackObfuscator.prototype.apply = function (compiler) {
1717
var _this = this;
18+
var isDevServer = process.argv.find(function (v) { return v.includes('webpack-dev-server'); });
19+
if (isDevServer) {
20+
console.info('JavascriptObfuscator is disabled on webpack-dev-server as the reloading scripts ', 'and the obfuscator can interfere with each other and break the build');
21+
return;
22+
}
1823
var pluginName = this.constructor.name;
1924
compiler.hooks.emit.tap(pluginName, function (compilation) {
2025
for (var fileName in compilation.assets) {

0 commit comments

Comments
 (0)