-
Notifications
You must be signed in to change notification settings - Fork 61
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
WIP: propose a framework for documentation #776
base: master
Are you sure you want to change the base?
Conversation
A common problem for SW projects is how to create documentation (both user oriented, describing how to use the tool, and developer oriented, describing concepts such as “design specifications”, “architecture descriptions”, "adrs"). This commit aims to show how we could create developer oriented documentation. It add a framework that picks the existing adrs markdown files, and deploy them to a static webpage. Benefits of the proposed approach: - documentation is in the same repo as the code (no risk of spreading it in different tools/repos); - documentation is versioned in the same way as code; - documentation can be still be read/visualized on github, but it can also be deployed locally on the machine where the repo has been cloned, or deployed to github page or similar; - the markdown files representing the documentation (in this case the adr) are not modified; - this approach could be common between multiple projects under the eclipse-cdt-cloud group; The same approach could be used to generate user oriented documentation, but it is outside the scope of this commit. See the README file to get going. Signed-off-by: Francesco Robino <francesco.robino@ericsson.com>
I tried to follow the instructions I get a message that it requires node 14. The project currently still requires only node 12.
Is there a way to make it work with node 12? |
The content of the documentation will have to be created (User Guides, Developer Guides etc), when if we go further with this documentation. I'm not fully clear how to deploy it so that people in open source can see the webpage. I wonder if it could run as part of the Github pages of this project. Any suggestion for this? |
Maybe when upgrading to latest Theia, which is supposed to work with node 14, this is not an issue anymore. |
@frallax Is there any update regarding this PR? |
let me summarize what has happened:
What I am working on lately is:
Something that still has to be decided is:
|
Thank you @frallax for the update. |
Same features as original Sidebar
Using gatsby Link enables automatic refresh when clicking on the item from the sidebar.
Before this commit, the sidebar was generated with one row per md file. After this commit, the sidebar is generated with one row per folder containing md files. This is not the final solution, but just shows how we can play with sidebar generation depending on how we want to distribute docs in the project or if we want to use front matter.
Added some comments to clarify the logic to create the configuration object for the new sidebar
From Sidebar2 to Sidebar
Updates:
This update does not address the questions listed in a comment above. Those are still open for discussion. Why did I do this? It is just to proof that if we want we can generate documentation (and a sidebar to browse it) automatically without having to use front matter in md files. However, I am still thinking that using front matter in md files could be beneficial. |
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
Excellent proposal! I can't wait to have a site for visualizing documentation. But I advise against using GatsbyJS because:
Due to these reasons I propose we adopt a different Framework for this task: SvelteKit. I created PR #896 for you to consider as a replacement for this one. |
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
@Rodrigoplp-work, you're welcome I think to formalize your review for this specific PR. I mean, by means of using Review changes, then Submit(ting) your review per above. Thanks! |
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Excellent proposal! I can't wait to have a site for visualizing documentation.
But I advise against using GatsbyJS because:
- The framework is dated. It was the best way (IMO) to build static sites when it was released, but many of its features and solutions are now outdated;
- Hard to maintain: Gatsby has been through some heavy breaking changes in the past (with versions 2.0.0 and 3.0.0) that required extensive refactoring. It is now already on version 5 (this PR uses v. 4);
- Large code base: Gatsby relies on plugins developed by its community to do what it does, like converting markdown files to html. Some of these plugins are large and outdated, causing the code base for a simple static site to be quite large in comparison to other frameworks available today;
- Fading community support: Gatsby was great because the JS community got highly involved when it was released. Plugins, discussions and support abounded. Today other frameworks are receiving more attention.
Due to these reasons I propose we adopt a different Framework for this task: SvelteKit. I created PR #896 for you to consider as a replacement for this one.
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto (rodrigo.pinto@calian.ca)
Adds a website in the "doc" folder to hold the documentation for Theia Trace Extension. Website built with [Svelte Kit](https://kit.svelte.dev). This PR replaces eclipse-cdt-cloud#776, which accomplishes the same goal but uses GatsbyJS. The proposal to replace Gatsby with Svelte aims at reducing the code base and adopting more modern solutions for the problem of rendering static documentation sites. Signed-off-by: Rodrigo Pinto <rodrigo.pinto@calian.ca>
A common problem for SW projects is how to create
documentation (both user oriented, describing how
to use the tool, and developer oriented, describing
concepts such as “design specifications”, “architecture
descriptions”, "adrs").
This commit aims to show how we could create developer
oriented documentation. It add a framework that picks the
existing adrs markdown files, and deploy them to a static
webpage.
Benefits of the proposed approach:
documentation is in the same repo as the code (no
risk of spreading it in different tools/repos);
documentation is versioned in the same way as code;
documentation can be still be read/visualized on github,
but it can also be deployed locally on the machine
where the repo has been cloned, or deployed to github
page or similar;
the markdown files representing the documentation
(in this case the adr) are not modified;
this approach could be common between multiple
projects under the eclipse-cdt-cloud group;
The same approach could be used to generate user oriented
documentation, but it is outside the scope of this commit.
See the README file to get going.
Signed-off-by: Francesco Robino francesco.robino@ericsson.com