Summary of request:
- Ability to see which classes are being used
- Ability to see how many usages there are of each class
- Ability to see whether a global class is empty at a glance (from the list)
- Ability to sort and filter based on number of usages and emptiness
- Ability to see usage locations for a class and click to go directly to them
Request details:
There are a few scenarios that crop up during development.
Occasionally we will inherit sites created by other developers / agencies. Also, working in a team, sometimes multiple people will work on a website.
When this happens, you may find there are classes that were created that aren’t named semantically or are seemingly redundant/duplicates.
In this case, we often find we are attempting to locate which blocks/pages these classes are used on. In the most basic sense, the aim is just to see whether they are being used at all so they can potentially be cleaned up.
It will be incredibly useful to be able to see which classes are being used, and how many times. As a bonus, if we can know where they are being used, it will be amazing.
Given the fact that Cwicly does tree shaking to optimise the global class stylesheet, I imagine that some of this information is already available, so it may just require adding a UI to make it accessible.
As a bonus feature, if we can also see when a global class is empty at a glance, this will also be useful.
Having a way to sort and filter this list based on number of usages or whether it is empty would be incredibly powerful.
As the cherry on the cake, having a dialog/popup that shows where each class is used and a link that allows you to go directly there is an absolute “killer” feature.