web-decorators
web-decorators copied to clipboard
Create a default adapter without express
Use https://www.npmjs.com/package/route-parser for route matching, implement the concept of routes and middlewares.
- [ ] Create the main handler function to give to http#createServer()
- [ ] Create the structure that takes the methods and patterns
- [ ] Create the api to add routes to the route container
- [ ] On request, dispatch the request to the right handler, from the pattern and method
- [ ] Extract path params from the request
- [ ] Extract query string params from the request
- [ ] Provide an API to read the request body
- [ ] Add response related tasks
- [ ] Add middleware related tasks