Node.JS API for the fmk-dosis-til-tekst-ts component
This project exposes an API that calls the fmk-dosis-til-tekst-ts library.
- Node.js latest version
- set environment variable
NODE_ENV=development. This is the default value if the variable is not set - run
npm installin the terminal - run
npm run devin the terminal, which should result in:
Server is running on port 8000.
- set environment variable
NODE_ENV=production - run
npm install --omit=devin the terminal - run
npm run startin the terminal, which should result in:
Server is running on port 8000.
-
The API should now be accessible at
http://localhost:8000/<endpoint>. -
Health check available at http://localhost:8000/health.
-
Swagger docs available at http://localhost:8000/docs.
- run
npm run swaggerin the terminal
The file swagger.json is created or updated at src/swagger.json.
- run
npm run eslintin the terminal
The linter reports any errors.