zoukankan
html css js c++ java
superagent-promise
var Promise
=
this
.
Promise
||
require
(
'promise
'
)
;
var agent
=
require
(
'superagent-promise
'
)
(
require
(
'superagent
'
)
, Promise
)
;
// method, url form with `end`
agent
(
'GET
'
,
'
http://google.com
'
)
.
end
(
)
.
then
(
function
onResult
(
res
)
{
// do stuff
}
,
function
onError
(
err
)
{
//err.response has the response from the server
}
)
;
// method, url form with `then`
agent
(
'GET
'
,
'
http://google.com
'
)
.
then
(
function
onResult
(
res
)
{
// do stuff
}
)
;
// helper functions: options, head, get, post, put, patch, del
agent
.
put
(
'
http://myxfoo
'
,
'data
'
)
.
end
(
)
.
then
(
function
(
res
)
{
// do stuff`
}
)
;
// helper functions: options, head, get, post, put, patch, del
agent
.
put
(
'
http://myxfoo
'
,
'data
'
)
.
.
then
(
function
(
res
)
{
// do stuff
}
)
;
查看全文
相关阅读:
ado.net
sql基础
css样式
HTML基础加强
socket网络编程
网络聊天室
多线程
WinForm基础
使用Maven插件(plugin)MyBatis Generator逆向工程
SpringBoot使用thymeleaf时候遇到无法渲染问题(404/500)
原文地址:https://www.cnblogs.com/Gbeniot/p/7326357.html
最新文章
数据库执行过程
EAN-13 编码规则
python 基础汇总(3)
python基础汇总(2)
python基础汇总(1)
python yield 和 yield from
DispatcherServlet与初始化主线
SpringMVC的历史
iOS 邓白氏编码申请流程
iOS 苹果开发者账户购买流程
热门文章
iOS 修改状态栏字体颜色(亲测,好用)
xcode及证书的问题
总结一下百度地图 定位 大头针 和划线和城市检索的功能
自定义模态转场动画
升级Xcode8后需要添加的一些权限
真机运行不了处理方案
关于判断邮箱 手机号等一系列的正则表达式。。。。。
iOS判断机型
Linq To XML
正则表达式
Copyright © 2011-2022 走看看