resource-router-middleware
resource-router-middleware copied to clipboard
:bicyclist: Express REST resources as middleware mountable anywhere
Can it be use for nested resource? e.g like Laravel https://laravel.com/docs/5.1/controllers#restful-nested-resources. If I have route like ```photos/:photos/comments/:comments``` how will I use your package?
Currently, when the `id` is undefined the router always defaults to `/:undefined` vs `/` The latter result accounts for request methods without the need for the URI fragment.
Can you give an example of running a test case for `index` for example (with `jest` or any other testing framework)
How would you add authentication middleware in this for a specific route? For example only in the put/patch/delete method?
I think the documentation could be improved, I'm using your boilerplate REST API and this (great) module is rather confusing to me. I think what it really lacks is a...
How can I load only some records ? examples : http://localhost:4040/api/ibge/2 http://localhost:4040/api/ibge?limit=10&page=3 thanks
Hi~ I want to do something like: GET /resources/:id/latest POST /resources/:id or GET /resources/:id/sub-resource/:sid I know maybe these APIs are not very restful, but how can I do it? Thanks
Could you please add possibility to use context inside `route`? Line [27](https://github.com/developit/resource-router-middleware/blob/master/resource-router-middleware.js#L27). ``` javascript router[fn](url, route[key].bind(route)); ```