I like BEM for it's structure and still use it in combination with scoped CSS in Vue, but it works without scoping as well.
Think of your component as the block, then structure down from there and keep it as simple as possible. If you run into naming problems, your component might be getting too big.
Do you use a design system or build your app from scratch?
That’s pretty much how I work as well, except for the scoped css in Vue. My components stay small, but the issue becomes that I have the need for so many components I run out of names for the various types. I should note that I don’t really work on your standard Dashboard UI, those components are easier to name. I work on quite creatively driven mockups (think games) that the components aren’t immediately obvious as to what they are. To give insight my current project has over 100 unique Vue components (though a handful are HOCs).
App(s) are built from scratch.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I like BEM for it's structure and still use it in combination with scoped CSS in Vue, but it works without scoping as well.
Think of your component as the block, then structure down from there and keep it as simple as possible. If you run into naming problems, your component might be getting too big.
Do you use a design system or build your app from scratch?
That’s pretty much how I work as well, except for the scoped css in Vue. My components stay small, but the issue becomes that I have the need for so many components I run out of names for the various types. I should note that I don’t really work on your standard Dashboard UI, those components are easier to name. I work on quite creatively driven mockups (think games) that the components aren’t immediately obvious as to what they are. To give insight my current project has over 100 unique Vue components (though a handful are HOCs).
App(s) are built from scratch.