Next.js Discord

Discord Forum

optimizePackageImports feature

Unanswered
Pink salmon posted this in #help-forum
Open in Discord
Pink salmonOP
Hi Folks,
My app takes about 21 seconds to compile every page (which is a rough DX) so I figured it was time to use the optimizePackageImports feature.

Any recommendations for hunting down the culprits of the uber-barrel-exports? I've tried what I thought would be the obvious one (@chakra-ui) but that hasn't solved my issue.

Is there some sort of analysis tool that I could use to see where the modules are coming from? I can see there are over 7000, as that's what the next cli spits out on every page load, but I don't get any more granularity than that.

Any help would be hugely appreciated by me and the whole dev team!

1 Reply

Toyger
probably something like that could help https://github.com/webpack-contrib/webpack-bundle-analyzer