Alireza
Alireza

Reputation: 79

Problem with importing Firebase into Xcode project

After following the steps, i could deal with error of "import Firebase" to my AppDelegate, but still can not configure firebase in my code!

I already created a firebase account and downloaded 'GoogleService-Info.plist' and added it to my project and also used 'pod init', edited it to add Firebase Core, Auth, Database' and 'pod install' to create xcworkspace. However after using 'import Firebase' in my AppDelegate, i received an error of 'Could not build Objective-C module Firebase'. I changed the product/scheme to 'Firebase' and the error was gone but still Firebase is not recognizable inside my code to be configured.

I would be so thankful for any clue!

Upvotes: 0

Views: 425

Answers (3)

Leo
Leo

Reputation: 21

structure

open project use .xcworkspace file, when use pod install framework

Upvotes: 1

ISS
ISS

Reputation: 416

So in the didFinishLaunchingWithOptions function in the AppDelegate.swift file, add FirebaseApp.configure() and make sure to delete. If you get the arm errors, make sure to stat a new project from scratch and add Firebase podfiles again. It should work.

Upvotes: 0

Leo
Leo

Reputation: 21

maybe you have open project use xcworkspace

Upvotes: 0

Related Questions