react-dev-loader
Advanced tools
Sorry, the diff of this file is not supported yet
+1
-1
@@ -11,3 +11,3 @@ let ReactDev = require('./lib/react-dev-loader'); | ||
| } | ||
| console.log(this.resource); | ||
| // console.log(this.resource); | ||
| let reactDev = new ReactDev(options); | ||
@@ -14,0 +14,0 @@ // console.log(source); |
+1
-1
| { | ||
| "name": "react-dev-loader", | ||
| "version": "2.0.0", | ||
| "version": "2.0.1", | ||
| "description": "", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
+33
-2
@@ -1,4 +0,4 @@ | ||
| ### 一个用来辅助 react 开发的工具 | ||
| ## 一个用来辅助 react 开发的工具 | ||
| 目前提供如下功能: | ||
| ### 目前提供如下功能: | ||
@@ -8,1 +8,32 @@ 1. 每个组件挂载和卸载时打印 log | ||
| 3. 组件更新时打印引起组件更新的 prop | ||
| ### 使用方法 | ||
| ```js | ||
| { | ||
| test: /\.js$/, | ||
| use: [ | ||
| { | ||
| loader: 'babel-loader', | ||
| options: { | ||
| presets: ['@babel/preset-env', '@babel/preset-react'], | ||
| }, | ||
| }, | ||
| { | ||
| loader: 'react-dev-loader', | ||
| options: {}, | ||
| }, | ||
| ], | ||
| exclude: /node_modules/, | ||
| }, | ||
| ``` | ||
| `options` 提供了一个可选项 | ||
| - `exclude` 忽略不需要的文件或文件夹 | ||
| ### 效果截图 | ||
|  | ||
| 如果你有其他需求可以来[github](https://github.com/onlyadaydreamer/react-dev-loader)提 issue 哦~ |
538760
3689.28%6
20%39
387.5%