Converting | Migrating iOS Project from Swift 2.3 to 3.0 in XCODE 8
There are more solution that you can came up, but i have these two solution
Solution 1:
Xcode itself providing a option to migrate from swift 2.3 to swift 3.0. Update your Xcode to the latest 8.0 and here you go.
Edit > Convert > To Current Swift Syntax
there you have an option to convert which version you want!
Solution 2:
In your Podfile, add use_frameworks! and pod ‘RealmSwift’ to your main and test targets. Paste the following at the bottom of your Podfile updating the Swift version to 3.0:
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings[‘SWIFT_VERSION’] = ‘3.0’
end
end
end
#enjoy_coding