-
-
Notifications
You must be signed in to change notification settings - Fork 488
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
Move chart data calculation to source code edges #81
Conversation
Only the entrypoints to inner modules now calculate the chart data
It no longer functions the same as chartData fetching was moved to higher layers.
Please review this @th0r soon so we won't have merge conflicts in the future. The changes in here should be safe for all the documented use cases. |
I noticed that I had forgotten to update the I fixed that, and checked that the contents of
|
|
I created a new major feature branch, |
The goal of this PR was to get
src/viewer.js
to a place where it no longer requires any other internal module.This PR supercedes #40 with a much less scary refactoring. The only potentially breaking change is the undocumented usage of
require('webpack-bundle-analyzer').start
export. As it was never part of the documented API, I thought it was safe to remove instead of figuring out how to still support it.I moved
client/
andviews/
root level directories, that were only a concern for the reporter UI, insidereporter/
root level directory. This also moved the build-time UI artefacts frompublic/
toreporter/public/
, cleaning up the root level folder structure a bit:I will follow-up with another PR where I will extract thesrc/viewer.js
to a completely new package, that will be created under@webpack-bundle-analyzer
npm organization, and I'll name the package as@webpack-bundle-analyzer/reporter-treemap
.This new package will be installed as a dependency of
webpack-bundle-analyzer
so that everything will still function as before. I want the first step of cutting out the reporter to be invisible to users of this package, so that we can release a minor version upgrade without breaking any users and have less things to worry about when the reporter package can be customized.More on these later.We'll figure this out later, and use a monorepo approach :)