5
要求我不能让我的头周围递延对象使用fb.api使用jQuery推迟
dfd = new $.Deferred();
FB.api('/me/posts?fields=id,story&access_token='+accessToken,function(response){
dfd.resolve();
//Do something with the result
});
dfd.done(alert(dfd.isDeferred()));
从我的理解中,.done应该只有一次的请求已完成,回调设置对象为解决火,然而,在请求完成之前,警报框会触发错误。
我错过了什么?
必须是简单的,谢谢 –