juanpablofernandez / SwiftyOnboard

A swifty iOS framework that allows developers to create beautiful onboarding experiences.
MIT License
1.25k stars 105 forks source link

Build fail on iOS 11/Swift 4 #19

Closed zacrose14 closed 6 years ago

zacrose14 commented 6 years ago

Trying to use this and I'm getting a build time error from Swift Compiler and it appears some changes from Swift 3 to Swift broke part..

Argument of '#selector' refers to instance method 'didTapPageControl' that is not exposed to Objective-C

'init(colorLiteralRed:green:blue:alpha:)' is unavailable: This initializer is only meant to be used by color literals

Argument of '#selector' refers to instance method 'tappedPage()' that is not exposed to Objective-C

adrum commented 6 years ago

If you are using CocoaPods, you can add this to the bottom of your Podfile:

post_install do |installer|
    installer.pods_project.targets.each do |target|
        if target.name == 'SwiftyOnboard'
            target.build_configurations.each do |config|
                config.build_settings['SWIFT_VERSION'] = '3.2'
            end
        end
    end
end
zacrose14 commented 6 years ago

That fixed it for now, thanks!