fetch-html-img:通过html文本抓取图片

时间:2021-03-22 13:06:14
【文件属性】:
文件名称:fetch-html-img:通过html文本抓取图片
文件大小:5KB
文件格式:ZIP
更新时间:2021-03-22 13:06:14
JavaScript fetch-html-img 文档锚链接 1.该库用作干什么? 通过html文本抓取图片 2.配置描述 主配置 参数名 数据类型 必填 默认值 简单描述 体现 htmlStr 细绳 是 :turtle: 页面的html文本 <html> ... </ html> 选择器 细绳 是 :turtle: 目标图片的css选择器 “ .wrapper img” saveDir 细绳 是 :turtle: 保存图片的目录,需要传绝对路径 path.resolve(__ dirname,“ ./imgDir”) 主持人 细绳 是 :turtle: 抓取网站的地址(为了防止一些图片的src没有http字符串的情况) “ ” setImgName 功能 否 :hollow_red_circle: 默认是随机10个字符 设置生成的图片名称模板 函数返回值就是生成的图片名称 img数字 数字 否 :hollow_red_circle: 9999 抓取的图片数量 sortRandom 布尔型 否 :hollow_red_circle: 错误的 是否
【文件预览】:
fetch-html-img-master
----index.js(2KB)
----package.json(637B)
----LICENSE(1KB)
----initConfig.js(2KB)
----README.md(2KB)

网友评论