Search code examples
iosgoogle-fabric

Initialize Fabric-Answeres in iOS with cocoa pods


I posted a post which was named "Initialize Fabric in iOS with cocoa pods", regarding initialization with crashlytics. It basically asked how to initialzie crashlytics with an API key, without having to go through info plist. That was solved by doing this:

Crashlytics.start(withAPIKey: FABRIC_API_KEY)

But then im trying to do the same for Answers:

Answers.start(withAPIKey: FABRIC_API_KEY)

But Answers doesnt have any .start method? How can I initialize this then?

It is later used in this line:

Fabric.with([Crashlytics.self, Answers.self])

Solution

  • Mike from Fabric here. Answers is included within Crashlytics by default, you only need to init Answers separately if you're not using Crashlytics. Using:

    Fabric.with([Crashlytics.self])
    

    is all you need to do.