mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-17 12:16:38 +08:00
28 lines
520 B
TypeScript
28 lines
520 B
TypeScript
|
|
window.fbAsyncInit = function() {
|
|
FB.init(
|
|
{
|
|
appId : '{your-app-id}',
|
|
xfbml : true,
|
|
version : 'v2.0'
|
|
}
|
|
);
|
|
|
|
FB.ui(
|
|
{
|
|
method: 'share',
|
|
href: 'https://developers.facebook.com/docs/dialogs/'
|
|
},
|
|
function(response) {
|
|
console.log(response);
|
|
}
|
|
);
|
|
|
|
FB.api(
|
|
"/me",
|
|
"POST",
|
|
function (fbResponse){
|
|
console.log(fbResponse);
|
|
}
|
|
);
|
|
}; |