Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bundled size is extremely high #189

Open
nikitph opened this issue Apr 15, 2024 · 0 comments
Open

bundled size is extremely high #189

nikitph opened this issue Apr 15, 2024 · 0 comments

Comments

@nikitph
Copy link

nikitph commented Apr 15, 2024

I am quite sure there is some config I must be missing as there is no reason the bundle size for this lib needs to be in MBs. Any suggestions?

Makua-202404-1513 30 33@2x
Makua-202404-1513 32 36@2x

here is my webpack config

`const path = require('path');
const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
const glob = require('glob');

module.exports = {
entry: {
'bundle.js': glob.sync('build/static/?(js|css)/main.*.?(js|css)').map((f) => path.resolve(__dirname, f)),
},
mode: 'production',
output: {
filename: 'build/static/js/bundle.min.js',
},
module: {
rules: [
{
test: /.css$/,
use: ['style-loader', 'css-loader'],
},
],
},
plugins: [new UglifyJsPlugin()],
};
`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant