Best Practices for Using Dev-Docs Effectively
- Set appropriate
internalTypeFilters
, codeFilters
, and nameFilters
to focus documentation on relevant code elements
- Specify correct
contextDirs
to provide AI with proper context
- Configure
mappings
to organize generated docs logically
2. Use Markdown Mode
- Enable Markdown mode when writing in-editor documentation
- Keep documentation close to related code for better maintainability
- Leverage version control to track documentation changes alongside code
3. Generate Context Regularly
- Use the "Generate Context" command frequently as code evolves
- Generate high-level context for folders to maintain up-to-date project overviews
- Leverage multi-file context generation for complex components
4. Leverage AI-Assisted Features
- Use the "Ask Dev-Docs A Question" command to get quick answers about your codebase
- Run the "Find Missing Documentation" command periodically to identify gaps
- Review and refine AI-generated content for accuracy
5. Maintain External Docs
- Use the "Populate External Docs" command to keep external documentation in sync with code
- Customize external doc generation using relevant dev-docs.json options
- Review generated external docs and make manual edits as needed
6. Integrate with Development Workflow
- Set up Git hooks to automatically update docs on commit/push
- Configure CI/CD pipelines to regenerate docs on merge to main branches
- Use generated API docs to keep API documentation current
7. Collaborate Effectively
- Share generated high-level contexts with team members for better code understanding
- Use AI-generated answers to common questions as a knowledge base
- Maintain a centralized docs site using the external docs generation feature
8. Continuously Improve
- Regularly review and update dev-docs.json configuration
- Provide feedback on AI-generated content to improve accuracy over time
- Stay updated on new Dev-Docs features and incorporate them into your workflow