autoresponse
Advanced tools
Comparing version 0.4.0 to 0.4.1
@@ -1,4 +0,10 @@ | ||
0.3.0 / 2020-01-21 | ||
0.4.1 / 2020-01-21 | ||
=================== | ||
* [^] 修复 `logLevel` 选项设置无效问题 | ||
0.4.0 / 2020-01-21 | ||
=================== | ||
* [^] 更新依赖,要求 `Node >= 8` | ||
@@ -5,0 +11,0 @@ * [^] mock 默认辅助的工具方法,使用更轻量级的日期库 [dayjs](https://github.com/iamkun/dayjs) 替代 [moment](http://momentjs.com/docs/) 日期库 |
@@ -8,3 +8,3 @@ /** | ||
var { pathToRegexp, parse } = require('path-to-regexp'); | ||
var {pathToRegexp, parse} = require('path-to-regexp'); | ||
var _ = require('lodash'); | ||
@@ -11,0 +11,0 @@ var util = require('./autoresponse-util'); |
@@ -87,3 +87,3 @@ /** | ||
var logType = LOG_LEVEL[logLevel]; | ||
if (logType.id < _logLevel) { | ||
if (logType.id < LOG_LEVEL[_logLevel].id) { | ||
return; | ||
@@ -90,0 +90,0 @@ } |
{ | ||
"name": "autoresponse", | ||
"version": "0.4.0", | ||
"version": "0.4.1", | ||
"description": "Autoresponse middleare using local data or proxy", | ||
@@ -43,4 +43,4 @@ "main": "index.js", | ||
"engine": { | ||
"node": ">= 6" | ||
"node": ">= 8" | ||
} | ||
} |
@@ -124,4 +124,4 @@ # autoresponse [![NPM Version](https://img.shields.io/npm/v/autoresponse.svg?style=flat)](https://npmjs.org/package/autoresponse) | ||
var server = new WebpackDevServer(compiler, { | ||
// install middlewares | ||
setup: function(app) { | ||
// install middlewares,if your webpack version is less than 3.0.0, using `setup` option instead of `before` option | ||
before: function(app) { | ||
var autoresponse = require("autoresponse"); | ||
@@ -128,0 +128,0 @@ app.use( |
505259