https://github.com/tw93/umi-plugin-console
☄️ 用于 umi 打包过程中配置各个钩子输出一些提示性的信息
https://github.com/tw93/umi-plugin-console
Last synced: 6 months ago
JSON representation
☄️ 用于 umi 打包过程中配置各个钩子输出一些提示性的信息
- Host: GitHub
- URL: https://github.com/tw93/umi-plugin-console
- Owner: tw93
- Created: 2020-08-19T08:48:15.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-08-19T13:21:00.000Z (over 5 years ago)
- Last Synced: 2025-06-27T07:44:51.553Z (7 months ago)
- Language: TypeScript
- Homepage:
- Size: 5.86 KB
- Stars: 5
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
Awesome Lists containing this project
README
# umi-plugin-console
[](https://npmjs.org/package/umi-plugin-console) [](https://npmjs.org/package/umi-plugin-console)
用于 umi 打包过程中配置各个钩子 log 输出一些提示性的信息,比较适合写命令行工具时候使用,友好提示用户,具体效果如下:

## Usage
```bash
# or yarn
$ npm install umi-plugin-console -D
```
Configure in `.umirc.js`,
```js
export default {
console: {
onPluginReady:
'插件初始化完成日志输出,在 onStart 之前,此时还没有 config 和 paths,他们尚未解析好',
onStart: '开始编译日志输出',
onBuildComplete: '构建完成日志输出,包括失败场景',
onDevCompileDone: '构建完成日志输出,没有失败场景',
onExit: '编译退出日志输出,dev 退出时触发',
},
};
```
## Options
- 参考上述使用说明,更多钩子可见
## Develop
```bash
# or yarn
$ npm install
```
```bash
$ npm run build --watch
$ npm run start
```
## LICENSE
MIT