re: I have been programming since I'm 10, Ask Me Anything! VIEW POST


What's the perspective to make a React/Vue/Angular atomic according to separate the components?

I having trouble in thinking how much components do I need in my SPA and separate.

Would be nice some wisdom.


That's a very common question in the Vuejs Berlin Meetup (that I'm organizing).

There's no definite answer to that of course. I usually separate something into its own component as soon as it works on its own but not if it's just a couple of lines that are definitely specific to the current component or page.

Don't treat specialised components. If there's something that you must probably don't reuse or would need to rewrite to make reusable you still can put it into a component if it is helping with readability

code of conduct - report abuse