Merge pull request #134 from failpunk/patch-2

Update rewriter code
This commit is contained in:
typicode
2015-06-24 09:09:03 +02:00

View File

@ -216,7 +216,7 @@ To add rewrite rules, use `jsonServer.rewriter()`:
server.use(jsonServer.rewriter({ server.use(jsonServer.rewriter({
'/api/': '/', '/api/': '/',
'/blog/:resource/:id/show': '/:resource/:id' '/blog/:resource/:id/show': '/:resource/:id'
}) }))
``` ```
Alternatively, you can also mount the router on another path. Alternatively, you can also mount the router on another path.