该项目使用面向对象方法封装了 Facebook 的 JavaScript 开发包。
示例代码:
<script src="app.js"></script> var FB = new OOFB('your_access_token_here'); // Get the info on Mark Zuckenberg (he's id is '4') var mark = new FB.User(4); // Since that is a promise, we can fire it up (to fetch the data) like this: mark.get(function(user) { console.log(user.name); // Prints "Mark Zuckerberg" });