Type Function Return value Boolean Revision 2017.3060 Keywords facebook, isFacebookAppEnabled See also facebook.*
Determines if a Facebook app is installed and accessible on the device. Some behaviors of the Facebook plugin differ depending on whether a Facebook app is installed or not. Using this API can help optimize the user experience depending on this factor.
facebook.isFacebookAppEnabled()
This function returns true
if a Facebook app is installed and accessible on the device, with the following caveats:
On iOS, this function is equivalent to system.canOpenURL("fb://")
. Because of this, the same gotchas for system.canOpenURL() apply.
On Android, this function will return true
for either the standard Facebook app or the Facebook Lite app.
local facebook = require( "plugin.facebook.v4" ) print( "Is a Facebook app installed and accessible? " .. tostring(facebook.isFacebookAppEnabled()) )