I've done all is mentioned here (https://www.parse.com/docs/ios_guide#fbusers/iOS) for implement in iOS the Facebook Login.
The problem is that i have an compile error "Use of unresolved identifier PFFacebookUtils"
near che line
PFFacebookUtils.initializeFacebook()
in AppDelegate. I've correctly imported the Parse and Facebook Framework into my project.
Are there some bug knowed in Xcode 6 Beta?
Parse docs doesn't mention this yet: After downloading the Parse iOS SDK, You should include the ParseFacebookUtils.framework
into your project, then import it in each file you want to use it, like you did for the Parse.framework
itself:
#import <Parse/Parse.h>// This use to be enough to use Facebook utilities
#import <ParseFacebookUtils/PFFacebookUtils.h>// But now we should import this framework as well to use Facebook utilitis
Parse team has separated the Facebook related classes from Parse API, hence a ParseFacebookUtils.framework
You may need to
import ParseFacebookUtils
in your AppDelegate
If you want to use PFFacebookUtils or/and PFLogInViewController with swift, you have to do this:
- For not V4 version:
#import <ParseFacebookUtils/PFFacebookUtils.h>
in bridging header and then import ParseFacebookUtils
in swift file. And call PFFacebookUtils.initializeFacebook()
somewhere, of course best place for this is application didFinishLaunchingWithOptions.
- For V4 version:
#import <ParseFacebookUtilsV4/PFFacebookUtils.h>
in bridging header and import ParseFacebookUtilsV4
in swift file. And call PFFacebookUtils.initializeFacebookWithApplicationLaunchOptions(launchOptions)
in application didFinishLaunchingWithOptions.
Of course you should have set your bridging header correctly and import frameworks.
Resolved! #import in bridging header
After the update to Parse/FacebookUtils, to import you do #import <Parse/PFFacebookUtils.h>