Advertisement
rodro1

js what mb used what package in app.js

Oct 2nd, 2019
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. I was suggesting bundle analyzer to get the correct size of each module included.
  2.  
  3. Here is the link -
  4. https://github.com/th0r/webpack-bundle-analyzer
  5.  
  6. Here is how to use this in Laravel mix
  7.  
  8. npm install --save-dev webpack-bundle-analyzer
  9. Then in your webpack.mix.js
  10.  
  11. var BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
  12.  
  13. mix.webpackConfig({
  14. plugins: [
  15. new BundleAnalyzerPlugin(),
  16. ]
  17. });
  18. Then run
  19.  
  20. npm run prod
  21. Wait for http://127.0.0.1:8888/ to be ready for your browser.
  22. You can remove this package after using.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement