Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: docs generator #1290

Merged
merged 43 commits into from
Dec 13, 2023
Merged

feat: docs generator #1290

merged 43 commits into from
Dec 13, 2023

Conversation

marcelovicentegc
Copy link
Member

@marcelovicentegc marcelovicentegc commented Nov 22, 2023

Summary

This is the first iteration related to #1030.

Resolves #1030 by leveraging typedoc and handlebars to generate docs from our code. It parses typedoc output to fit our needs, organising it into our next-docs folder structure and file split.

Adds a new package, @vtex/docs-generator, to shoreline. Its README contains information, development instructions and best practices to generate meaningful documentation from our libraries. Please check it out.

⚠️ This PR contains a patch from https://github.com/RealShadowNova/typedoc-json-parser. I'm opening a PR there anytime soon...

The script is not yet implemented on git hooks nor CI. Ideally, we will iterate a couple more times generating docs before including it on one of these automated processes.

From this PR onwards, we must

Examples

Take a look at the changes of this PR. It updates all existing docs to the generated ones as described in #1356 🥳

Also resolves #1367 (it was quite fast to implement the evolution)

@marcelovicentegc marcelovicentegc requested a review from a team as a code owner November 22, 2023 00:17
Copy link

vercel bot commented Nov 22, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
shoreline-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 13, 2023 0:44am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
admin-ui-docs ⬜️ Ignored (Inspect) Visit Preview Dec 13, 2023 0:44am

@marcelovicentegc marcelovicentegc marked this pull request as draft November 22, 2023 00:17
@marcelovicentegc marcelovicentegc self-assigned this Nov 22, 2023
@marcelovicentegc marcelovicentegc added the documentation Improvements or additions to documentation label Nov 22, 2023
@marcelovicentegc marcelovicentegc marked this pull request as ready for review November 28, 2023 00:13
package.json Outdated Show resolved Hide resolved
packages/next-docs/pages/components/button/code.mdx Outdated Show resolved Hide resolved
packages/next-docs/pages/components/button/code.mdx Outdated Show resolved Hide resolved
packages/next-docs/pages/components/button/props.mdx Outdated Show resolved Hide resolved
packages/next-docs/pages/components/button/props.mdx Outdated Show resolved Hide resolved
packages/docs-generator/src/handlers.ts Outdated Show resolved Hide resolved
packages/docs-generator/src/handlers.ts Outdated Show resolved Hide resolved
@marcelovicentegc marcelovicentegc merged commit 60d1a14 into main Dec 13, 2023
7 checks passed
@marcelovicentegc marcelovicentegc deleted the feat/auto-generate-docs branch December 13, 2023 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Documentation generator evolution Investigate programatic typescript documentation
2 participants