AlmogBaku / ngFacebook

DEPRECATED Angular facebook service
MIT License
261 stars 70 forks source link

Add AppEvents part #49

Open rtimothee opened 9 years ago

rtimothee commented 9 years ago

I noticed that the part AppEvents of the Facebook SDK was not implemented. I quickly created a function in your library to solve my problem but it's not very "clean".

$facebook.AppEvent = function($msg){
    var deferred=$q.defer();

    return $facebook.promise.then(function(FB) {
        FB.AppEvents.logEvent($msg);
        return deferred.promise;
    });
};

If you have time this will be great to add this fonctionnality with all the options ! thx