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
Docs recommend selector.Component_variantName, but we've been using .Component_VariantName in most projects. Is there a reason for one over the other? Is there another alternative that we could be using?
The text was updated successfully, but these errors were encountered:
❌ Adding selectors means you need to update them in both styles.ts and styles.module.css whenever you need to change them - it's easier to leave it as .Component and only update in styles.ts.
✅ Selectors are required to be able to use the CLI command that autogenerates styles.ts. There is however an ongoing discussion as to whether to keep the CLI command; if we get rid of it we should 100% stop recommending that selectors be used by default.
VARIANT CASE
🔶 We have used PascalCase for pretty much every project so far
🐪 Using camelCase means that any props generated by the CLI tool will also be camelCase, as per convention - <Panel wide> vs <Panel Wide />. Again, this is irrelevant if we get rid of the CLI tool.
Docs recommend selector.Component_variantName, but we've been using .Component_VariantName in most projects. Is there a reason for one over the other? Is there another alternative that we could be using?
The text was updated successfully, but these errors were encountered: