Open fabiospampinato opened 1 year ago
Sorry I don't know what this means or why this would be useful. Can you say more? Are you asking for the ability to hide certain sections of the graph? Why do you need this? If you are having trouble seeing something that's small, you can already use zooming in to see it.
Sorry, that wasn't very descriptive 😅
Are you asking for the ability to hide certain sections of the graph?
Yes, basically, and the portions of the graph that get hidden depend on a couple of strings written in "include" and "exclude" fields somewhere, rollup-plugin-visualizer
has this feature.
It sounds kind of useless, but it is useful in some scenarios, for example:
The include field could help you answer the question "is module X in the bundle?", which isn't always obvious or immediate to find out, if the flame chart looks like this for example:
Or maybe you know that something is in the bundle, you'd like to inspect it further, but you don't know exactly where in the graph it is. The "include" field could function as a sort of search feature for that.
The exclude field can be useful in situations where you have something like the following (but scaled up to the point where it actually becomes a bit of a problem), where maybe you want to have a closer look at "stubborn-fs" and at "duper", you've already looked at "is", and zooming in isn't a perfect solution because that would zoom into "is" also, and there's only so much space on screen. Maybe if there's enough space on screen with the ability to hide portions of the graph you could see all the information that you need on screen without needing extra zooming or scrolling, which would be ideal.
The include field in some cases can also provide a quicker way to exclude what you want, and vice versa, so both of them are useful, though a single field might do with it can accept multiple queries in it.
I think it would be useful if something like that was implemented. Potentially the input field could just show up on cmd+f and not waste any pixels until needed, in that could be a concern.
It'd be useful to be able to include and exclude modules in the bundle analyzer.