Suchjs is an extensible and powerful data simulation library, with external extend library, can intercept front-end requests and simulate a response data.

Usage

  • > In Node Environment

    >----------Recommend----------
    # Install the npm package `such-cli`
    npm install --save-dev such-cli
    # Initialize
    such init
    >----------OR----------
    # Install the npm package itself
    npm install --save-dev suchjs
  • > In Browser

    <!--import the script, please download the file and upload to your own service machine-->
    <script src="https://cdn.jsdelivr.net/gh/suchjs/such@master/dist/such.min.js"></script>
    <!--You can also use some package tools, such as webpack, just install the library package like in the nodejs.-->

Demo

Here are just some examples to show the ability of `Suchjs`. Please see the document for more details.

:string

:number

:increment

:date

:regexp

:ref

:dict

:cascader

template literal