This repo contains the source code and infra used to build and the deploy the website: https://openjs-security-program-standards.netlify.app/.
This website is built using Docusaurus 2 and generator-fast-documentation
$ npm i
$ npm start
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
$ npm run build
This command generates static content into the build
directory and can be served using any static contents hosting service.
- Check standard-version docs
- Check Husky docs
Most of the content of this website is autogenerated with Github Actions, this include the content from docs/implementations and docs/details files.
- Go to Actions: Sync and update Compliance Checks and run the action manually from the
main
branch. how-to - This will generate a PR with the title
[AUTO] Sync with dashboard database
and it will assign it to you (direct access). Please review the content and merge it when you feel ready.
Once you have updated the data/checks.json file, you can update the website by running the following commands:
npm run populate-details
npm run populate-implementations
This will autopolulate the details and implementations sections of the website, respectively. So make sure to commit the changes.
If you want to enhance any page, you can do so as you would in any other project (via a Pull Request, example). However, please note certain rules, as some parts of the files are dynamically generated, and your changes could be overwritten.
Rules
- Metadata is added automatically. Manual additions or modifications to metadata are not allowed.
- You can contribute any content to any file, but avoid making changes within the sections enclosed by specific tags, as these sections are dynamically generated. For example:
OK <!-- DESCRIPTION:START --> AVOID (AUTOMATED) <!-- DESCRIPTION:END --> OK