You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be nice to set up a new env variable to turn off class minifying.
Since it is enabled by default and not listed on CHANGELOG.md, it could cause an issue which is hard to detect. Please refer my comment here: #246 (comment)
The text was updated successfully, but these errors were encountered:
It looks like you're depending on the class names that Aphrodite is generating which we generally discourage and we earlier discussed explicitly not working to keep the format of the class names fixed: #229 (that is, the format of those class names might change in any release).
The way that we at Khan Academy get around this is by adding extra properties or class names onto the elements that you need to find to uniquely identify them without depending on the Aphrodite class names. For instance, to mark elements that we might interact with during end-to-end tests, we explicitly mark those elements with a data-test-id attribute like <div data-test-id="header-button" /> and then use css selectors like [data-test-id="header-button"] to find them in the DOM. You could do something similar, either by adding extra class names other than the ones Aphrodite is generating, or adding extra data- properties yourself.
Would that solve the problem you're having? We'd really like to not add features to modify the class names that are generated when we don't want people to be depending on them. Sorry we haven't been explicit about that, I've been busy and haven't gotten around to publishing those thoughts into a more concrete form.
It would be nice to set up a new env variable to turn off class minifying.
Since it is enabled by default and not listed on CHANGELOG.md, it could cause an issue which is hard to detect. Please refer my comment here: #246 (comment)
The text was updated successfully, but these errors were encountered: