1. 需求
4. 实现方案
- 使用vue.js 或者 原生html
- 使用echarts图表作为数据可视化呈现形式
- txt监听尝试使用node.js 中对fs模块 或者 进行轮询监听,达到实时更新的效果
```javascript
/**
- Created by ctw */
const fs = require(‘fs’); var fileName = ‘t.txt’; fs.watch(fileName,( function () { var count = 0; return function(){ count++; console.log(“文件” + fileName + “ 内容刚刚改变。。第” + count + “次” ); }; })()); console.log(“watching file…”); ```
5. 项目周期
- 3-4 天, 预计周二之前完成