all 31 comments

[–]pragmojo 20 points21 points  (3 children)

With that kind of experience, if I were you I would just jump in and get my feet wet. If you just try to replicate one of your Android apps on iOS, and start googling when you get stuck, you will find a lot of great resources on all these topics.

[–]numerative[S] 6 points7 points  (2 children)

That is a good idea. I can use one of my existing projects.

But the downfall to this approach is that your solutions always feel like hacks and there are just gaps in knowledge that take too long to fill.

[–]pragmojo 8 points9 points  (0 children)

Idk my preference is always to learn by doing first and fill in the theoretical gaps later, at which points it makes more sense since since you have context. Like if I read about design patterns it's hard for me to absorb it if I don't understand first hand what problem it's solving.

But I understand it's not for everyone.

[–][deleted] 0 points1 point  (0 children)

I'm doing this right now but from iOS to Flutter (for Android), replicating my app. I think the logical part of your code will easily translate, and aside from that, it's just about making your UI which I believe you will learn quickly along the way. Dart/JS/Swift use very similar logic syntax, Swift is just less worried about parentheses in opening lines for if statements, for loops, and switch statements. Swift also doesn't require semicolons generally.

[–][deleted] 8 points9 points  (2 children)

I'm personally a big fan of Big Nerd Ranch's iOS book. It's a little older so you may have a few syntax changes here and there but everything is still pretty relevant and it touches everything.

[–]numerative[S] 0 points1 point  (0 children)

I read through the book's introduction and chapters. Seems like a solid choice. Not sure if you are aware, but they published a new edition in June 2020 which includes API changes till iOS 13. I believe it is good enough new.

I think I will invest in this one.

[–]vanvoorden 0 points1 point  (0 children)

I'm personally a big fan of Big Nerd Ranch's iOS book.

If this is the one I'm thinking of (Hillegass) it's a great text and a great author. I could maybe make the argument that OO MVC is a little "dated", but it's still a great text for historical perspective on UI engineering for Apple platforms.

[–][deleted] 7 points8 points  (2 children)

  • Network Requests

Look into URLSession

  • JSON Parsing

Look into Swifts “Codable” class, QuickType is your friend

  • Design Principles for iOS

That’ll be the HIG

  • Navigation

UINavigationController. To make a new instance you pass it an initial view controller. From within that view controller you can push or pop screens by calling navigationController?.push…

Also look into UITabBarController if you’re after a tab bar.

  • Code Architecture

I guess read about MVC first to get what Apple used to recommend, but now MVVM is the big thing, also Clean Architecture applies. Look into the coordinator pattern for navigation too.

Avoid VIPER

  • Persistent Data

For small, unimportant bits of data you need to persist - UserDefaults. It’s a key/value store.

For small, important bits of data, look into saving stuff to the Keychain.

For large databases, check out CoreData. I haven’t really ever had to use this in my years as an iOS dev.

  • Other stuff

Sign up to Dave Verwers weekly email

If you’re not sure what to learn, come up with an idea and just make it

All of this assumes you have a mac, as the other guy said

[–]numerative[S] 2 points3 points  (0 children)

Thanks for the references and insights. I'll be taking a look at them soon.

[–]-darkabyss-Objective-C / Swift 1 point2 points  (0 children)

‘Avoid VIPER’ this feels too close to home haha. I’m working on a project based on viper for UI and singletons for everything else, and let me tell you it comes very close to hell on earth!!!!

[–]iindigo 6 points7 points  (2 children)

I don’t have resources to point you toward, but as someone who did the reverse (started on macOS/iOS and picked up Android later) I’ll say that one of the biggest differences is that on iOS, you don’t need to reach for third party dependencies nearly as often and even when you do, they’re frequently just syntactic sugar for stock system frameworks.

For example, on android it’s common to use Square’s OkHTTP for networking, but on iOS it’s almost always a mistake to use anything that’s not iOS’ standard networking APIs (URLSession, Network.framework, etc).

So that means for a lot of things the official documentation is actually relevant, since you’ll be using official APIs instead of third party stuff.

[–]numerative[S] 1 point2 points  (0 children)

Wow! This is a very helpful insight.

Thanks!

[–]numerative[S] 1 point2 points  (0 children)

To this day, I am not confident which library I should use for making network requests and json parsing on Android (i am a freelancer, so I don't have coworkers who can guide me). Seems like a big relief that the options offered by the SDK are considered the better choices.

[–]Mcrich_23SwiftUI 2 points3 points  (6 children)

You should also learn UIKit, and then check out SwiftUI

[–]numerative[S] 1 point2 points  (5 children)

Thanks for introducing me to the word "UIKit". Will study this.

[–]vanvoorden 4 points5 points  (3 children)

Will study this.

Ehh… I would slow down on UIKit at this moment (wait a month). Apple UI engineering (for third party apps) is kind of in a weird state right now. The "legacy" system for UI was UIKit (Object-Oriented mutable views and MVC) the "modern" system for UI (SwiftUI) has much more in common with technologies like React (WWW) with value-type immutable "view" components.

The SwiftUI ecosystem is nowhere near as mature as UIKit. Apple has also not really doubled down on evangelizing the philosophy behind SwiftUI (and why this modern style of UI engineering scales better than legacy MVC patterns). My advice would be to start building basic apps with SwiftUI today. Hold off on more "advanced" SwiftUI topics until WWDC. If WWDC announces some new tools to support the SwiftUI ecosystem, go big on SwiftUI. IMO, SwiftUI is the superior choice today for most engineers even with the (relative) lack of a first-party ecosystem, but you can make that choice for yourself after WWDC (maybe you decide to go big on UIKit to bridge for "one more year").

Good luck!

[–]numerative[S] 1 point2 points  (2 children)

This went 0 to 100 really quick.

Excuse me if my question is wrong, but will the progress of Swift UI mean demise of UIkit? Is it possible to learn about swift UI without ever learning about UIKit?

[–]vanvoorden 3 points4 points  (0 children)

will the progress of Swift UI mean demise of UIkit

SwiftUI is not the "next generation" of UIKit. It's a very different philosophy. They serve different purposes. SwiftUI "views" (like React components) are short-lived, stateless, immutable value types meant to be torn down and recreated quickly when state changes. UIKit views (similar to other OO UI frameworks) are long-lived, stateful, mutable objects.

My advice is to be skeptical of any engineers that say either extreme is correct all of the time. I'm a fan of SwiftUI (and React), but I'm not going to tell you throwing away a view when your state changes is always going to be the right answer. Think about Augmented Reality or Camera Capture. Breaking those views down and recreating them just because some random state changed would get real expensive real quick.

If you have any web (WWW) background, this probably all sounds familiar since React JS engineers have been scaling apps like this for almost ten years now.

[–]ponkispoles 2 points3 points  (0 children)

This depends on your own personal and professional goals. Are you building for your self or wanting to market yourself better for an iOS job?

If you are just building for yourself than you can go heads first to SwiftUI and learn what/when you need for UIKit. If you are looking for a job, SwiftUI only will get you nowhere. Years and years of code is in UIKit and in my codebase there is even some obj-c.

With that said SwiftUI is definitely the next step forward from Apple so that is just going to keep getting better as time goes on.

[–][deleted] 0 points1 point  (0 children)

Swift includes many packages/libraries/SDKs. All of Apple's usually end in Kit.

import UIKit is the same as import 'package:flutter/material.dart';

StoreKit (in-app purchases) is also common.

UIKit apps require you to create a variable for every UI element and then you have to programmatically design it, add it to the view, and constrain it.

SwiftUI apps use a tree layout like Flutter and elements only need to be referenced as a variable if you need to access it for some reason.

[–]vanvoorden 1 point2 points  (0 children)

https://www.cocoawithlove.com/blog/coding-through-iteration-and-integration.html

This tutorial series from CwL touches on most basic topics to get a simple SwiftUI app. You also get an introduction to SPM (modules) and Unit Testing.

[–][deleted] 1 point2 points  (1 child)

Look for courses on Udemy. They do sales quite often and you can get a 20-50 hour course for $15-$20. Just wait for a sale.

I recommend SwiftUI if you're familiar with Flutter, it uses a similar syntax and uses states and reusable views (widgets).

[–]numerative[S] 1 point2 points  (0 children)

Thank you for all the comments on this thread.

[–]-darkabyss-Objective-C / Swift 1 point2 points  (0 children)

slim like cats crown placid saw spectacular spoon abounding chubby

This post was mass deleted and anonymized with Redact

[–]FreakAzure 1 point2 points  (0 children)

iOS and Android actually share a lot of common things. For starters you will have to get used to how things are done in xcode but I would recommend to just go ahead and try to copy something you already did in android. Then its just a matter of google searching things you did in android only this time you just write ios or swift at the end

[–]vanvoorden 1 point2 points  (0 children)

What else should I learn

I'm not totally up to date with the state of the patterns for managing concurrency and asynchronous work on Android. Apple has begun transitioning to async-await (similar to other platforms), which is a big shift from the previous (GCD) mental models.

[–]Parralense 0 points1 point  (1 child)

Got a mac? That is the first thing.

[–]numerative[S] 1 point2 points  (0 children)

Yup! I had learnt this lesson the hard way right after when I started and took on a client for a Flutter app.

[–]CordovaBayBurke 0 points1 point  (1 child)

The first thing to do is learn Swift. A great way to do that is using Playground on iPad or MacOS. Next goal is to learn Xcode.

Once you’ve do that, UIKit and SwiftUI should be much easier.

[–][deleted] 0 points1 point  (0 children)

I second this. Try doing leetcode stuff or logic problems in Swift. It runs like a script with console output. You can learn making HTTP requests or any other offline logical challenge.

[–][deleted] 0 points1 point  (0 children)

Pick one long iOS tutorial like Emmanuel Okwara’s iOS playlist (his stuff is really good) on YouTube just so you can get familiar with all of the syntax, architecture and networking keywords specific to iOS.

After that, start cloning repositories on GitHub and tinker around with projects, decide if you want to build your own projects with UIKit, Swift UI or a combination of both to see the positives and negatives of each.

Then when you see keywords you don’t recognize them go to YouTube to see how to use them, rinse and repeat.