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

chore: evaluate and port Conrado's PR #9

Open
lucaaamaral opened this issue Mar 21, 2025 · 2 comments · May be fixed by #11 or #12
Open

chore: evaluate and port Conrado's PR #9

lucaaamaral opened this issue Mar 21, 2025 · 2 comments · May be fixed by #11 or #12

Comments

@lucaaamaral
Copy link
Collaborator

Problem

Conrado's PR magma/magma#15604 propose updates for the docussaurus and other improvements on documentation.
It brings too many changes that is difficult to evaluate.

Solution

Evaluate and separate into different PRs, each with a clear and single purpose to ease evaluation and approval.

Non-goals

Other changes outside of Conrado's proposal.

@lucaaamaral lucaaamaral changed the title chore: evaluate and port Conrado's PR https://github.com/magma/magma/pull/15604 chore: evaluate and port Conrado's PR Mar 21, 2025
@see7e
Copy link
Contributor

see7e commented Mar 24, 2025

Changes

Removed

  • No need for docusaurus/blog/ as discussed in Slack, and as the existing text is not relevant to the project, it has been removed.
  • Removed docusaurus/README.md as it is already present information duplicated with another files like docs/howtos/documentation_development.md.
  • Removed docusaurus/package-lock.json as the local development should be done with yarn.
  • Removed unused static files.
  • Remove HomepageFeatures components as was only being imported and not used.

Added

  • Added docusaurus/docs/howtos/documentation_development.md as to give instructions on how to develop documentation.
  • Added docusaurus/docker.package.json to include the dependencies needed to build the containers.

Updated

  • Improved docusaurus/.dockerignore refenrencing the the other JS modules that are not needed when building the container.
  • Updated docusaurus/package.json to include the latest versions of the dependencies.
  • Included at docusaurus/Dockerfile the the new instructions to build the containers of Development and Production.
  • Improved index.js to include the new components and remove the unused ones.

@see7e
Copy link
Contributor

see7e commented Mar 24, 2025

Notes

  • Check if package-lock.json is needed in the repository.
  • Confirm repository name for GH Pages deployment:
    // Set the production url of your site here
    url: 'https://magma.github.io',
    // Set the /<baseUrl>/ pathname under which your site is served
    // For GitHub pages deployment, it is often '/<projectName>/'
    baseUrl: '/magma/',

Translations

Is possible to make two types of translations in Docusaurus:

  • Pages: Will not be possible to use React components as the text to be translated will need to be hardcoded in the js file. For that run the following command:
    yarn run write-translations -- --locale <locale>
  • Markdowns: Run the following command:
    mkdir -p i18n/<locale>/docusaurus-plugin-content-docs/current
    cp -r docs/** i18n/<locale>/docusaurus-plugin-content-docs/current
    This will create a folder with the translated markdowns. The translated markdowns will be in the i18n folder.
    Using this method will be needed to manually update all the markdowns for each language.
    TODO Find a simpler way to translate.

@see7e see7e linked a pull request Mar 24, 2025 that will close this issue
1 task
@lucaaamaral lucaaamaral linked a pull request Apr 2, 2025 that will close this issue
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants