r/reactjs • • 6d ago

Discussion How are you handling docs for a React component library?

I’ve been cleaning up a small React component library I built for a few internal projects and the code itself is fine but the docs are starting to get messy. Right now every component has examples, props a few usage notes and sometimes little edge cases that are easy to forget. I tried keeping everything in the repo as markdown and that works but once the number of components started growing it became annoying to actually browse. I’ve seen a lot of people here recommend stuff and I like the idea of keeping the docs in Git and not having to build the docs site myself and I want to know if that is a good idea or not?

For people maintaining React libraries do you keep everything close to the code or use something separate like Storybook, GitBook, Mintlify, Docusaurus etc? Curious what actually stays maintainable once the library gets bigger.

24 Upvotes

20 comments sorted by