Sticking with Swift 1 and making app for IOS7 and above - ios

I have few questions that I was considering while making an app. The app supports ios7 and above. Its being written in swift 1.2 and I came across few articles that it's better to switch the code to Swift 2. The problem is some frameworks that is being used does not support swift 2 just yet.
1) Is it possible to stick with swift 1.2 and continue deploying for iOS 7 and above?
2) Once Xcode 7 is official, do we need to update all the code to Swift 2 or can continue with Swift 1.2 for some time until all the frameworks upgraded to Swift 2.
Thank you

1) You don't have to switch to Swift 2 immediately, but you have to stick with Xcode 6 and there's some inconvenience such as not being able to test on iOS9.
2) It's easy to upgrade Swift 1.2 code to Swift 2, my opinion is to wait until the frameworks support Swift 2.
Good luck!

Related

Can you still program in xcode 7 with swift 2?

Im working on a school project to build an iOS application in Swift. I saw that they updated to Swift 3.0 and now many tutorials don't work. My question is can you download xCode 7.3.1 and still work in Swift 2? So that I can follow the tutorials on the web?
My application only has to work on a emulator. So not in de App store
Thanks!
Yes you can use swift 2.2 in Xcode 7 and 2.3 in Xcode 8 by enabling the Use Legacy Swift Language Version in Build setting (SWIFT_VERSION = 2.2)
Swift 2.2.1 and Swift 2.3 are very similar, with key changes being related to SDK differences.

xcode 8 doesn't support indexPathsForVisibleRows in iOS 8

I have a project and use a lot of indexPathsForVisibleRows. Our project support iOS 8.0+ users. We migrate from Xcode7 to Xcode8 recently and find that Xcode 8 just support indexPathsForVisibleRows for only iOS9.0+ which doesn't work on iOS8. That is a disaster. Could anyone can help me?
For Objective-C and Swift 2.3 & under, the indexPathsForVisibleRows property is still marked as working from iOS 2.0 (a.k.a. the beginning) & onwards.
If you're using Swift 3 (which comes with Xcode 8), then you'll be limited to iOS 9 & newer (as the documentation states here).
If this were my problem I would probably choose to write some kind of helper function / class method in Objective-C via a bridging header solely for this issue.

Xcode 7 is out. What about submission with Xcode 6 and swift 1.2?

I have an application in review and it has been implemented with swift 1.2 and Xcode 6.x. In case Apple rejects my build I've to do the required fixes and submit it again. I've started working on the port to swift 2 but some of the libraries that I use have not been updated or they have dropped support for iOS 7 updating to swift 2.0... bad situation. That said, probably it takes some days (hopefully) to get back to a completely working project.
1) in the meanwhile can I still compile my current code with Xcode 6 swift/1.2 ? does Apple accept this kind of submission or they requires a build created with Xcode 7.
2) Can I avoid switching to swift 2.0 and use anyway XCode 7?
You can still use Xcode 6 and Swift 1.2. Apple will eventually require the newer tools but the now older one is still fine.
Of course you can't take advantage of any iOS 9 features this way but at least make sure your app works under iOS 9.

Upgrading a Swift 1.1/1.2 project from Xcode 6 to Swift 2 project on Xcode 7

I have a project that I've been working on with my friend on Swift 1.1/1.2.
Unfortunately, when I upgraded my Xcode to the latest version, I noticed that the app will no longer compile and there are lots of errors.
Is there a way for Xcode 7 to compile for Swift 1.2?
If not, how do I get the old version of Xcode which does not use Swift 2?
Is Swift 2 app backward compatible with Swift 1 apps?
Can Swift 1.2 app run on iOS 9?
Are most developers using the Swift 2 now or not?
In Xcode start with Edit->Convert->To Latest Swift Syntax...
You may still have errors that you will have to resolve manually. Read the Xcode Release Notes to see what changed in Swift 2.

swift will I be forced to remake my app's code when swift 2.0 is released

I have made an app using swift 1.2.
Will I be forced to rebuild my entire using swift 2 when its released?
Or can I still make updates to my app using swift 1.2 code?
It's my understanding that Xcode 7 uses Swift 2, and Xcode 6.x uses Swift 1.2.
Apple will probably continue to support Xcode 6.x for some time after Xcode 7 goes GM. During that time you should be able to support your Swift 1.2 code. However, it's not a good idea to depend on old developer tools. You should think about migrating to Swift 2 once Xcode 7 is released.
When i used xcode 7.beta 4, i converted my code for swift 2. when i ran the same code with xcode 7.beta 5, again i ran into few more swift related errors. better keep calm until Apple releases the final xcode version which supports swift 2+

Resources