refactor(app): Refactor display name utils #16537
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes EXEC-773
Overview
Now that we have a definitive locations for general app utils, all general utilities should now be imported through places like
local-resources
and not from the internals of component directories. One of the biggest culprits of violating this rule isCommands
. We use a lot of these utilities elsewhere.This PR serves as a general refactor for display name utils, which entails:
local-resources
protocolAnalysis
, pass only what we need.commands
. I actually caught a couple more unnecessary cases of iterating throughprotocolAnalysis
, so this refactor reduces TC by O(2n) in some spots.modules
orlabware
when it could in fact be an object and not an array. I guess in practice, this probably doesn't happen much, since I've personally never seen any tickets about this.04b6ad3 Contains the functional changes.
d350e0d is just a million lint/test fixes.
Test Plan and Hands on Testing
Risk assessment
lowish-medium.