Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/amir-arad/typescript-service-template
template for typescript dockerised service
https://github.com/amir-arad/typescript-service-template
Last synced: 4 days ago
JSON representation
template for typescript dockerised service
- Host: GitHub
- URL: https://github.com/amir-arad/typescript-service-template
- Owner: amir-arad
- Created: 2020-10-25T17:42:48.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2022-10-05T18:43:31.000Z (about 2 years ago)
- Last Synced: 2024-10-20T07:45:06.483Z (29 days ago)
- Language: TypeScript
- Size: 232 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Template typescript service
A typescript service that works with docker and shit
## Developer instructions
### Cloning this template
duplicate this repo
replace `typescript-service-template` with the name of the service you want to create### Installing workspace
to install a development environment, you need to have nvm and git installd.
Then, `git clone` this repo locally.
copy `.env.sample` into `.env` so that you have an initial configuration.
run:
```
$ nvm use
$ npm install
$ npm test
```
and that's it, you've just installed the development environment!This project is written with [VSCode](https://code.visualstudio.com/) in mind. specifically configured for these extensions: [dbaeumer.vscode-eslint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint), [esbenp.prettier-vscode](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode).
### test
`npm run test`
runst code checks and then execute internal tests.
`npm run test:quick`
only executes internal tests.
`npm run test:quick -- --watch`
run tests in watch mode.
### clean
`npm run clean`
Removes any built code and any built executables.
### build
`npm run build`
Cleans, then builds the service and docker image.
Your built code will be in the `./dist/` directory, the docker image will be written to the local docker exporter.
### End-to-end Testing
`npm run test:e2e`
runs end-to-end tests against a built docker image (you need to run `npm run build` beforehand, though).