-
-
Notifications
You must be signed in to change notification settings - Fork 9.2k
Closed
Description
After minimalization by uglify quotation marks were removed from string
config:
var webpack = require("webpack");
module.exports = {
output: {
filename: "dist/index.js"
},
context: __dirname,
entry: "./index.js",
module: {
loaders: [
{ test: /\.html/, loaders: ["html-loader"] },
]
},
plugins: [ new webpack.optimize.UglifyJsPlugin({ }) ]
}index.js:
console.log( "text: "+ require("./index.html") );index.html:
<span class="quick-search-shortcut" >
<i class="icon-loupe" ></i>
</span>result:
! function (o) {
function r(e) {
if (t[e]) return t[e].exports;
var n = t[e] = {
exports: {},
id: e,
loaded: !1
};
return o[e].call(n.exports, n, n.exports, r), n.loaded = !0, n.exports
}
var t = {};
return r.m = o, r.c = t, r.p = "", r(0)
}([function (o, r, t) {
var e = t(1);
console.log("text: " + e)
}, function (o, r) {
o.exports = "<span class=quick-search-shortcut><i class=icon-loupe></i></span>"//removed quotation marks in class attribute
}]);Metadata
Metadata
Assignees
Labels
No labels