https://github.com/iamteppei/seed-node-azurefunc
Seed NodeJS Azure Function
https://github.com/iamteppei/seed-node-azurefunc
Last synced: 10 days ago
JSON representation
Seed NodeJS Azure Function
- Host: GitHub
- URL: https://github.com/iamteppei/seed-node-azurefunc
- Owner: iamteppei
- Created: 2020-09-11T11:18:10.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2026-05-25T11:12:39.000Z (18 days ago)
- Last Synced: 2026-05-25T13:10:42.273Z (18 days ago)
- Language: TypeScript
- Size: 1.11 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# seed-node-azurefunc
A seed project for Serverless Function REST API
Stack
- Azure Function
- Serverless Framework
- Express JS
- Typescript
- MongoDB
## Version specification
- node: v12.16.3
- TypeScript v4
## IDE recommendations and setup
- VSCode IDE
- Eslint vscode plugin
- Prettier vscode plugin for linting warnings (auto fix on save)
- Add the following setting in vscode settings.json
```json
"eslint.autoFixOnSave": true
```
## Dev setup
- Install azure-cli with homebrew `brew update && brew install azure-cli`
- Install serverless-cli `npm install -g serverless`
- Install all the dependencies using `npm install`
- To run the server with watch use `npm run start`
- To run the test cases in watch mode use `npm run test:watch`
- To run the test cases without watch mode use `npm run test`
- To run the test coverage without watch mode use `npm run test:cov`
## Setup ENV variables
Create **serverless.env.local.yml** at the same level with serverless.yaml and update with your local configuration
```yaml
MONGO_DB_NAME:
MONGO_URI:
```
## Access URL
```bash
GET http://localhost:7071/api/core/ping
```
## Test
- Unit Test: We are using Jest for assertion and mocking
## Git Hooks
The seed uses `husky` to enable commit hook.
### Pre commit
Whenever there is a commit, there will be check on lint, on failure commit fails.
### Pre push
Whenever there is a push, there will be check on test.