【文件属性】:
文件名称:my-http:简化http请求的NodeJS模块
文件大小:3KB
文件格式:ZIP
更新时间:2021-06-15 00:44:04
JavaScript
我的-http
为普通的 http/https 任务提供辅助函数。
var http = require ( 'my-http' )
// saves "all.json" to current working directory
http . download ( 'http://nodejs.org/api/all.json' )
// saves "all-2015.json" to current working directory
http . download ( 'http://nodejs.org/api/all.json' , 'all-2015.json' )
http . readText ( 'http://nodejs.org/api/all.json' , function ( text , url ) {
console . log ( url +
【文件预览】:
my-http-master
----index.js(109B)
----test.js(366B)
----package.json(393B)
----LICENSE(1KB)
----lib()
--------readText.js(392B)
--------download.js(850B)
----README.md(447B)