she is going to sink the tweets in the UIViewController on the viewdidload! wow you broke this video up into sections very well. such advanced tutorial!
Finally a video that shows how to refactor from basic MVC to MVVM!!!! On top of that, it uses Combine! You are the best! If you can do more MVVM videos that would be great
As a software engineer, but not as a Swift developer full time, just for my own app: this is incredibly helpful for learning how to make my own code better. This is awesome.
Thank you, Karen. The section on @Published and UIKit help me out of a jam. I have been doing a lot of SwiftUI lately and when I went back to UIKit, things weren't working due to the will-set behavior.
This is excellent as a tutorial. a lot of hand on practices. your channel is great keep up the good work. would really like to see more videos like this. Advanced tutorials would be even better. All of UA-cam is filled with tutorials for beginners.
While a lot of this went over my head for now I love the way you break things down and show how to refactor it! Looking forward to checking out more of your videos. :-)
This is a good question and not an easy one. Most people go always with weak, because it will never crash your app. But weak means you have to deal with optionals. If I am calling on self inside a closure and I know the closure has self as its only owner, then I use unowned. Maybe this post explains it better vojtastavik.com/2019/10/21/why-you-should-use-unowned-more-often/.
UA-cam is filled with absolute shit tutorials and they all have these massive followings, like LBTA. It's shit code. I'm so glad you're doing this. Keep doing this. Let's clean this stuff up LOL
Thanks for the motivating words! I was watching LBTA in the very beginning of my iOS learning. But I realised soon that there is very little valuable information in it. I think people like it because he makes it sound very easy and he skips the more advanced stuff.
Just a comment. View Model should only concern itself with Presentation logic. Eg, how to compose & setup a certain view, what state should the view have, what will happen when a button is tapped, etc. TwitterApi struct is definitely Domain logic so it should go to the Model. ViewModel shouldn't even know that the Twitter API existed. It only concern itself with the tweets that has been mapped into their primitive types like string, int, float, Data, etc, and ready to be used by the Views. Anyway, that's not really why I am here though. If I were to break down the software engineering of the code, it will take quite some time. I'm just here to learn Combine. Thanks for the content. I use RxSwift all the time and I just found this video out to help me moving from Rx to Combine.
Okay, one more comment. "Why not use Codable". Because YAGNI. You Ain't Gonna Need It. We just use what we need to use at the time. So if you only need to Decode the JSON, you don't really need Codable. We can refactor it to Codable when we do need to do both Encoding and Decoding.
There are a million ‘intro to Combine’ videos you can check out. But very few ‘here’s what you can actually do with Combine’, especially at this pace and level. Before long you’ll be as glad for this as I am!
Hi Katrin)) use `self.` is not required with [unowned self] ... ... and in JSON file we have `profile_image_url_https` key. Therefore we can remove chunk of code - ⚠ remove in TwitterAPI - var jsonDecoder and in.decode() in param decode: use JSONDecoder() ✅ add to model of User - private enum CodingKeys: String, CodingKey { case name case profileImageURL = "profile_image_url_https" } ⚠ remove /.replacingOccurrences(of: , with: )()/ in ViewController (what in fact UITableViewController) in tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) method ✅ as a result line will look like - / cell.profileImage.sd_setImage(with: URL(string: tweet.user.profileImageURL)) / I think it looks much neater))
Love this one. It’s good to see how you use Combine to optimize a project.
she is going to sink the tweets in the UIViewController on the viewdidload! wow you broke this video up into sections very well. such advanced tutorial!
She is a good teacher indeed
I love how you gently explain that the other you tubers method is awful :) Great video thanks
Finally a video that shows how to refactor from basic MVC to MVVM!!!! On top of that, it uses Combine! You are the best! If you can do more MVVM videos that would be great
As a software engineer, but not as a Swift developer full time, just for my own app: this is incredibly helpful for learning how to make my own code better. This is awesome.
This is very informative, thank you!
Thank you, Karen. The section on @Published and UIKit help me out of a jam. I have been doing a lot of SwiftUI lately and when I went back to UIKit, things weren't working due to the will-set behavior.
This is excellent as a tutorial. a lot of hand on practices. your channel is great keep up the good work.
would really like to see more videos like this. Advanced tutorials would be even better. All of UA-cam is filled with tutorials for beginners.
Fantastic! Your talking through your thought process really helps me understand the subject. Bravo. Much appreciated.
While a lot of this went over my head for now I love the way you break things down and show how to refactor it!
Looking forward to checking out more of your videos. :-)
Woman you are a gem
Great Code Great Delivery thanks for your work.
Thanks and welcome
You are THE BEST at explaining Combine. Could you do a video on error handling? Which streams should handle the error, which ones should ignore it
Thank you! You just give me courage to try SwiftUI
compact and perfect lecture
Thanks for awesome video
Thank you for more of these reviews!!!
Incredibly detailed!
Thanks for Sharing This Tutorials
great work!
Thanks!
I thought Decodable worked for both cases. Can you please make a video of a simple project using Combine, teaching the simple stuff of MVVM as well?
Great job!
Great tutorial. Can you recommend any resources for learning combine for beginners?
You can have a look at this post www.swiftyplace.com/blog/how-to-learn-combine-framework. I used the books from Ray Wenderlich and Donny Wall.
nice
Well explained, thanks! How do you decide where to use weak self vs unowned self?
This is a good question and not an easy one. Most people go always with weak, because it will never crash your app. But weak means you have to deal with optionals. If I am calling on self inside a closure and I know the closure has self as its only owner, then I use unowned. Maybe this post explains it better vojtastavik.com/2019/10/21/why-you-should-use-unowned-more-often/.
UA-cam is filled with absolute shit tutorials and they all have these massive followings, like LBTA. It's shit code. I'm so glad you're doing this. Keep doing this. Let's clean this stuff up LOL
Thanks for the motivating words!
I was watching LBTA in the very beginning of my iOS learning. But I realised soon that there is very little valuable information in it. I think people like it because he makes it sound very easy and he skips the more advanced stuff.
Why not use ".replaceError(with: )" insead of "catch { _ }" ?
Just a comment. View Model should only concern itself with Presentation logic. Eg, how to compose & setup a certain view, what state should the view have, what will happen when a button is tapped, etc. TwitterApi struct is definitely Domain logic so it should go to the Model. ViewModel shouldn't even know that the Twitter API existed. It only concern itself with the tweets that has been mapped into their primitive types like string, int, float, Data, etc, and ready to be used by the Views.
Anyway, that's not really why I am here though. If I were to break down the software engineering of the code, it will take quite some time. I'm just here to learn Combine. Thanks for the content. I use RxSwift all the time and I just found this video out to help me moving from Rx to Combine.
Okay, one more comment. "Why not use Codable". Because YAGNI. You Ain't Gonna Need It. We just use what we need to use at the time. So if you only need to Decode the JSON, you don't really need Codable. We can refactor it to Codable when we do need to do both Encoding and Decoding.
This seems way too advanced.
There are a million ‘intro to Combine’ videos you can check out.
But very few ‘here’s what you can actually do with Combine’, especially at this pace and level.
Before long you’ll be as glad for this as I am!
Hi Katrin))
use `self.` is not required with [unowned self] ...
... and in JSON file we have `profile_image_url_https` key.
Therefore we can remove chunk of code -
⚠ remove in TwitterAPI - var jsonDecoder and in.decode() in param decode: use JSONDecoder()
✅ add to model of User -
private enum CodingKeys: String, CodingKey {
case name
case profileImageURL = "profile_image_url_https"
}
⚠ remove /.replacingOccurrences(of: , with: )()/
in ViewController (what in fact UITableViewController) in tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) method
✅ as a result line will look like - / cell.profileImage.sd_setImage(with: URL(string: tweet.user.profileImageURL)) /
I think it looks much neater))