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

[RFC]: Create documentation for individual package consumption #13

Open
3 tasks done
kgryte opened this issue Sep 3, 2021 · 1 comment
Open
3 tasks done

[RFC]: Create documentation for individual package consumption #13

kgryte opened this issue Sep 3, 2021 · 1 comment

Comments

@kgryte
Copy link
Member

kgryte commented Sep 3, 2021

Description

This RFC proposes to create a different version of the package documentation for installing and using individual packages.

Currently, the API docs are oriented around the main project and use nested import/require paths (e.g., @stdlib/math/base/special/sin. To facilitate individual package consumption, it would be nice if a user could toggle the docs and see specific instructions and examples for using individual packages (e.g., @stdlib/math-base-special-sin).

There are a couple of approaches which come to mind:

  1. If a user has toggled to the individual package docs version, we could do README processing client-side, where we update import/require paths and add an install section after loading a README fragment from the server.
  2. We could perform pre-processing where we generate individual package README fragments during the website build process. When a user loads individual package docs, we would fetch the individual package README fragment from the server and simply display as is to the user.

I think my preference would be the latter, if only because of SEO and less client-side load.

Related Issues

No.

Questions

No.

Other

No.

Checklist

  • I have read and understood the Code of Conduct.
  • Searched for existing issues and pull requests.
  • The issue name begins with RFC:.
@kgryte
Copy link
Member Author

kgryte commented Sep 3, 2021

For preprocessing of READMEs, I think we are fairly close to being able to do this today. We just need to extract the logic found in the individual package publishing script into a separate package which we can independently consume.

cc @Planeshifter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant