Answer the question
In order to leave comments, you need to log in
Webpack completely rebuild assembly (Laravel Elixir)?
There is a simple project where I just use css, js font-awensome, jquery/
config:
module: {
loaders: [
{
test: /\.png|jpg|jpeg|gif$/,
loader: "file?name=[1]®Exp=src/(.*)"
}, {
test: /\.woff(2)?(\?v=[0-9]\.[0-9]\.[0-9])?$/,
loader: "file?name=fonts/[name].[ext]"
},
{
test: /\.(ttf|eot|svg)(\?v=[0-9]\.[0-9]\.[0-9])?$/,
loader: "file?name=fonts/[name].[ext]"
}, {
test: /\.scss$/,
loader: ExtractTextPlugin.extract('style-loader', 'css-loader?!sass!autoprefixer-loader?browsers=last 2 versions', {publicPath: '../'})
}
]
},
// Use the plugin to specify the resulting filename (and add needed behavior to the compiler)
plugins: [
new ExtractTextPlugin("css/[name].css"),
new webpack.optimize.UglifyJsPlugin({}),
new webpack.ProvidePlugin({
$: "jquery",
jQuery: "jquery"
})
]
[14:30:44] Version: webpack 1.13.2
Asset Size Chunks Chunk Names
fonts/OpenSans-Italic.ttf 213 kB [emitted]
fonts/fontawesome-webfont.eot 76.5 kB [emitted]
fonts/fontawesome-webfont.woff 90.4 kB [emitted]
fonts/fontawesome-webfont.ttf 153 kB [emitted]
fonts/fontawesome-webfont.svg 392 kB [emitted]
fonts/OpenSans-Regular.ttf 217 kB [emitted]
fonts/OpenSans-Bold.ttf 225 kB [emitted]
fonts/fontawesome-webfont.woff2 71.9 kB [emitted]
fonts/OpenSans-Light.ttf 222 kB [emitted]
fonts/OpenSans-Semibold.ttf 221 kB [emitted]
main.js 134 kB 0 [emitted] main
css/main.css 81 kB 0 [emitted] main
main.js.map 998 kB 0 [emitted] main
css/main.css.map 89 bytes 0 [emitted] main
WARNING in main.js from UglifyJs
Side effects in initialization of unused variable slick [./resources/assets/js/main.js:1,0]
Condition always true [./~/slick-carousel/slick/slick.js:20,0]
Dropping unreachable code [./~/slick-carousel/slick/slick.js:22,5]
Dropping unused variable edgeWasHit [./~/slick-carousel/slick/slick.js:2654,0]
Condition always true [./~/jquery/dist/jquery.js:10179,0]
Child extract-text-webpack-plugin:
Answer the question
In order to leave comments, you need to log in
using elixira is a little bit wrong as webpack does all the work instead!
just put a limit on the file loader and it won't bother you all that often
{
test: test: /\.png|jpg|jpeg|gif$/,
loader: "file?name=[1]®Exp=src/(.* )?limit=5000"
}
and that's it! good luck
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question