npm i json-server
{
"posts": [
{ "id": 1, "title": "json-server", "author": "typicode" }
],
"comments": [
{ "id": 1, "body": "some comment", "postId": 1 }
],
"profile": { "name": "typicode" }
}
json-server --watch db.json
json-server --watch db.json --port 3004
Resources URL로 이동 시 간단히 사용하기 좋은 서버가 세팅된 것을 확인할 수 있다.