0

I'm new here and also new to iOS and Swift development.

I'm trying to use GeoFire for my first project and install the library using Cocopod. I can see the GeoFire files in my project directory. However, I am having problem referencing it in my ViewController.

var geofire: GeoFire?

The above always result in the error "use of declared type 'GeoFire'", what is the install step that I'm missing?

Thanks!

4

1 回答 1

0

I can see that you're using Swift. Geofire's README file mentions:

Using GeoFire with Swift

GeoFire supports Swift out of the box! In order to use GeoFire and Swift from CocoaPods, add the use_frameworks! line to your Podfile, like so:

use_frameworks!

pod 'GeoFire', '>= 1.1'

Did you do that? Remember to run pod install after you modify your Podfile if it needs modifying.

Did you also add import GeoFire at the top of the view controller where you want to use it?

于 2016-02-21T19:21:38.290 回答