Home

Awesome

<p align="center"> <img src="https://raw.githubusercontent.com/joon610/imageRepo/main/image/mockup-server/icon.png" alt="logo" width="128px" height="128px"> </p>

MockUp Server GitHub license GitHub release

DownLoad

Project setup

git clone https://github.com/joon610/mockup-server.git
cd mockup-server
yarn install

Compiles and hot-reloads for development

yarn dev

Compiles and minifies for production(electront)

build:electron

Why make it

Used when developing Front-end and Back-ends at the same time. Since Front-End developers have to develop without a server, there is a possibility of future problems (async, variable names, object types, API, etc.). You can reduce the problems later by developing

How to use it

  1. Make Directory. (will be API path)
  2. make Json File in Directory ( response Data)
  3. select Root Directory
  4. Start Server .. finish.
  5. Share to Github for Front-End and Back-End developers
  6. Manage using GitHub

Initialize directory.

<img src="https://raw.githubusercontent.com/joon610/imageRepo/main/image/mockup-server/process.png" alt="directory">

Click Events

Setting Files

CRUD

<a id="indexJson"></a> index.json

// response json
[
  {
        "id": "1",      //dynamic api key   ex) localhost/bla/:id
        "name": "Sara",
        "age": "13"
    },
    {
        "id": "2",
        "name": "teddy",
        "age": "14"
    }   
]

<a id="crud"></a>CRUD (Create, Read, Update ,Delete)

Post, Get

//response data
[
    {
      "id": "1", 
      "name": "Sara",
      "age": "13"
    },
    {
      "id": "2",
      "name": "teddy",
      "age": "14"
    }   
]
//response data
[
    {
      "id": "1",   
      "name": "Sara",
      "age": "13"
    }
]

Put

//request data
{
  "id": "3", 
  "name": "Sara",
  "age": "13"
}
//response data
[
    {
      "id": "3",   
      "name": "Sara",
      "age": "13"
    },
    {
      "id": "2",
      "name": "teddy",
      "age": "14"
    }   
]

Delete

//response data
[
    {
        "id": "2",
        "name": "teddy",
        "age": "14"
    }   
]

License

MIT License