The DiagRAMS API docs is a web-site for explain how use the API with DiagRAMS.
The DiagRAMS api docs is backed with the Next.js framework. We chosen it for:
- its good defaults (lots of optimization out of the box),
- its React oriented approach,
- its TypeScript compatibility.
We also use styled-jsx that allows us
to simply use CSS but in a scoped way. We chosen it for:
- its very low learning curve (compared to TypeScript/React/NextJS 😅),
- its fit with our very custom design that enforce us to have a lot of custom components
We use Jest for testing and components librairies in order to build interfaces starting by components.
You must clone this repository before doing any of the next steps :
git clone git@github.com:DiagRAMS-Technologies/api-docs.gitOnce ready, just install the dependencies, husky and compile the project:
npm i
npm run prepare
npm run buildThen, run the development server:
npm run devYou can then test your whole build:
npm tOr you can just run the unit tests:
npm run jest
npm run jest -- --watchOpen http://docs.diagrams.localhost:3000 with your browser to see the result.