- TypeScript 100%
| config | ||
| server | ||
| src | ||
| .eslintignore | ||
| .eslintrc | ||
| .gitignore | ||
| LICENSE.md | ||
| package-lock.json | ||
| package.json | ||
| README.md | ||
| tsconfig.json | ||
Declarative JSON API Server Framework
The objective of ParkourJSON is to provide a concise, typed, non-verbose, and declarative way of implementing a JSON API server without the need for code generation (an unnecessary and annoying step).
A 'JSON API' in this sense is an API that:
- Only responds to JSON-formatted requests.
- Only responds with JSON-formatted responses.
Getting Started
Simply clone or fork this project.
Forking is recommended to allow for downstream merging of future improvements.
After cloning or forking, see the sample API implementation in the src directory.
How to Fork
To create a new project based on this framework, do not use the 'fork' feature of GitHub. Instead, follow these steps:
-
On GitHub, create a new empty repository (let's call this the project repo).
-
git clonethe project repo locally andcdinto it. -
Add this repository as an upstream remote to the local project repo clone, we will name the remote
framework.:git remote add framework https://github.com/ParkourOps/parkour-json -
Create a local branch on the project repo clone called
frameworkwhich will reflect themainbranch of this repository.git fetch framework main git checkout -b framework --track framework/main -
Create the
mainbranch on the project repo.git checkout -b main git push -u origin main -
Install the Node dependencies and get developing!
npm install
Work to Do
In order of precedent:
-
Implement global middleware.
-
Implement an OPTIONS handler on all possible routes which should respond with concise representation of the API good enough to be used as user documentation.
-
Implement unit tests.
-
Implement functional tests.
-
Documentation!
-
Improve typing to further improve development experience.