gulp - gulp-html - 如何验证外部页面
问题描述
我尝试通过 gulp-html 验证外部测试服务器的 html。
https://www.npmjs.com/package/gulp-html https://github.com/validator/gulp-html
我不明白如何为非本地站点配置“src”值。
文档中的示例是:
const html = () => {
return gulp.src('src/index.html')
.pipe(validator())
.pipe(gulp.dest('dist/'));
};
我想用“https://example.com”替换“src/index.html”。
当我尝试它时,我收到一个错误:
Error: File not found with singular glob: /path/to/project/https://example.com
解决方案
推荐阅读
- swift - 将 INNER JOIN 查询从 SQLite 转换为 SQLite.Swift
- tensorflow - 如何在flask中同时预测由tensorflow(.pb)模型和keras模型(.h5)组成的多个模型?
- python-3.x - 请求库引发 urllib 连接错误
- java - 我的 ConnectFour 游戏在正方形网格但不在矩形网格中时有效
- ruby-on-rails - 对危险方法爆炸的规则感到困惑
- kubernetes-apiserver - preStop hook inside pod using K8s API
- traefik - Traefik v2 Middlewares not being detected
- c# - 无法从 DataTable 中选择 DataRow
- python - How to load a comment form in DetailView?
- html - How to set different td sizes with inputs in them?