Slack context: https://expensify.slack.com/archives/C01GTK53T8Q/p1748586074870539
The unused style searcher check was problematic:
- was broken by a prettier change that updated formatting without changing any style usages
- looks like it has some false positives (saying things are unused when they're not) as well as false negatives (missing some styles that are actually unused)
- has some kind of memory leak and sometimes crashes
So as discussed in slack we are going to disable the check for now.
The scope of work in this issue is to fix the problems with the script and add it back (ideally in its own workflow, separate from prettier).
My suggestion is to drop the regex-based approach, and instead use the ts compiler API as described in this comment.
Slack context: https://expensify.slack.com/archives/C01GTK53T8Q/p1748586074870539
The unused style searcher check was problematic:
So as discussed in slack we are going to disable the check for now.
The scope of work in this issue is to fix the problems with the script and add it back (ideally in its own workflow, separate from prettier).
My suggestion is to drop the regex-based approach, and instead use the ts compiler API as described in this comment.