One of the most common reusable component mistakes I see: They're not...


One of the most common reusable component mistakes I see: They're not discoverable.

I often ask teams "Where are your reusable components?"

Their answer: They show me a components folder that's a mix of page components, single-use components, and reusable components. 👎

The solution: Colocate similar things.

Store globally reusable components in a well-named, dedicated folder.

That said, a well-named and organized folder isn't enough. You need good docs too. Lots of good options:

Storybook
Ladle
Docz
Custom via tools like react-docgen

View original on X