以前のリビジョンの文書です
モック用のAPIサーバーが簡単に作成できる。
$ mkdir jsonsever $ cd jsonserver
$ npm install -g json-server
{ "users": [ { "id": 1, "name": "safa"}, { "id": 2, "name": "hana"} ] }
{ "/users/:id": "/users/?id=:id" }
>json-server --watch db.json --routes routes.json \{^_^}/ hi! Loading db.json Loading routes.json Done Resources http://localhost:3000/users Other routes /users/:id -> /users/?id=:id Home http://localhost:3000 Type s + enter at any time to create a snapshot of the database Watching...