0.2.3 • Published 8 years ago

restmock v0.2.3

Weekly downloads
48
License
-
Repository
github
Last release
8 years ago

restmock

Mock REST response on Server or Browser.

Server Mock

It can create a quick REST server by specifying routes in a json configuration file, additionally supporting static path.

restmock configure file : default mock.json

Browser Mock

It replaces window.XMLHttpRequest, and load mock.json in target project as configuration.

  • only support browserify bundling
  • steps
    • $ npm install restmock
    • write mock.json in root of target project
    • add require('restmock') to project main file
    • you have to remove require('restmock') in production environment.

Configuration

It supports all express method, with more specifically following route type

  • get
  • post
  • patch
  • put
  • delete
  • static : create a static folder with response as target folder

Example

0.2.3

8 years ago

0.2.2

8 years ago

0.2.1

8 years ago

0.2.0

8 years ago

0.1.2

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago

0.0.4

9 years ago

0.0.3

9 years ago

0.0.2

9 years ago

0.0.1

9 years ago