You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Generate website API docs from code comments #1341
For context, there were some attempts also on the rn repo a long time ago: react/react-native@eb7dbc8 but as far as I know it's not actually used. I can reach out to a couple folks to verify the state of that script logic
It has its own quirks. For instance, you have to manually concatenate the lines, parse parameters AST-style, and other things. It's doable, but not very friendly/maintainable. Would be interested to learn whether TypeDoc is better in this regard.
Activity
kelset commentedon Mar 31, 2022
yes pls! 👏
For context, there were some attempts also on the rn repo a long time ago: react/react-native@eb7dbc8 but as far as I know it's not actually used. I can reach out to a couple folks to verify the state of that script logic
UPDATE: it looks like the logic above was never used, but there was also this other attempt: https://github.com/facebook/react-native-website/tree/main/sync-api-docs but this one too has never been used
kelset commentedon Apr 5, 2022
on the Expo side of things, they use a solution based on https://typedoc.org/ to export JSON
You can find the logic here: https://github.com/expo/expo/blob/main/docs/components/plugins/APISection.tsx + https://github.com/expo/expo/tree/main/docs/components/plugins/api
tido64 commentedon Apr 5, 2022
Just an FYI, we are currently using TSDoc to generate the API tables for the
tools-*'sREADMEfiles:rnx-kit/scripts/src/commands/updateApiReadme.js
Line 8 in 99854bb
It has its own quirks. For instance, you have to manually concatenate the lines, parse parameters AST-style, and other things. It's doable, but not very friendly/maintainable. Would be interested to learn whether TypeDoc is better in this regard.