AppForce1: news and info for iOS app developers
AppForce1: news and info for iOS app developers
Doing all kinds of new things, learning as you go…
One awesome announcement this week. My regular news articles, and loads of info about the articles I mention.
Here are this week's articles:
- Using decorator pattern to add architectural non-intrusive analytics in Swift
- Migrating our Objective-C SDK to Swift – RevenueCat
- Tasks in Swift explained with code examples - SwiftLee
- Develop a command-line tool using Swift Concurrency
- Optimise your networking layer with Combine - Efficient networking for SwiftUI apps | Peter Friese
Runway
Put your mobile releases on autopilot and keep the whole team in sync throughout. More info on runway.team
Lead Software Developer
Learn best practices for being a great lead software developer.
Rate me on Apple Podcasts.
Send feedback on SpeakPipe
Or contact me on Mastodon: https://hachyderm.io/@appforce1
Support my podcast with a monthly subscription, it really helps.
My book: Being a Lead Software Developer
Hi, and welcome to the 65th episode of my podcast. My name is Leenarts. And I've been developing software for over 19 years developing iOS apps for over nine years, and I'm running that code cache for over eight years. If you're an iOS app developer, you should listen to my podcast because it will keep you updated on interesting articles, conference and events you might not have heard about in this episode, I'm going going to talk about using decorator pattern to add architectural non intrusive analytics in Swift migrating our objective C SDK to Swift tasks in Swift explained with code examples, develop a command line tool using Swift concurrency, and optimize your network layer with combined. As you could already tell, at the start of this episode, there's something new. In my previous episode, I already talked about it a little bit. But nowadays, I have a sponsor on the podcast runway is a product that takes off your release process and makes it more robust, collaborative and hands free. It allows you to release on time and increase your confidence in what you're shipping with a true picture of the feature completeness of what you are actually releasing. It's an integration tool between the App Store and the Play Store, and all kinds of other services that you might be using in your environment. So you can think about GitHub, GitLab, Bitbucket, JIRA, linear Pivotal Tracker, and several CI CD pipelines. So that circle ci betrivers, Jenkins, GitHub actions get lab CI and Travis CI. And they are working on a lot of other integrations as well at the moment. They also have integration with Slack. And they allow monitoring with box next century and Firebase. So just in a one or two minutes, I'm already mentioning a lot of interesting and cool products. And what runway does is integrate this all together into a singular dashboard that allows you to stay in control of everything that's happening on your app releases. They showed me a demo video, and I'm going to talk more with the company on what the product does. But already I can tell it's a great fit for me, my podcast and my audience. So I hope you like them as well check them out, they're sponsoring my podcast for a year. And later in the year, I will have an interview dedicated with somebody working at runway to really dig into this person, and also to see what the company runway actually produces as a product with a more in depth view, and what it could bring to an iOS app developer. So I want to express my thanks to runway for the trust they have put in me and my podcast. And I hope that we have a long and interesting relation into the future. Here in the Netherlands to our next batch of relaxations on the COVID restrictions seem to be coming. So right now we are allowed to basically do our shopping and that's about it, do some sports. But hopefully, in a few days time, we can actually go out and do the more enjoyable things in life again, so go out to the movies have a dinner somewhere in a restaurant, those kinds of things. Looking forward to that, because my wife and I have already some plans for our family to do some things to really huddle up with the four of us and and Auntie George out his company. Yeah, my son, he's still enjoying his, his school. He's actually having an interesting experience here, because the group is getting too big. And they're starting a new entry class. And the teacher actually opted for him not to be moved into this entry class, because he's very connected to the older kids in the group, because there's two age brackets that are actually primary school classes quite often. On the other hand, my daughter, she's really enjoying her gymnastics, she had like her first full week of training in a in a good facility. And already, you could tell that she's really enjoying it. And at home, she's telling all the new things that she's learning. And yeah, she did some first things for her on IBM, like, cartwheels, and she's now working on some other sort of jump on this high beam. So that's like, a five meter long thing. That's like 10 centimeters wide. And for some reason, she's able to jump and do all kinds of crazy stuff on that thing and actually land on it. If I tried to do that I would break all kinds of bones. So she's enjoying it. So that's good. Because you know, what's the always tell if the kids are happy, then the parents are also happy. Good. And well, and I hope to the COVID restrictions are relaxed very soon. Last week, there was the iOS conference, it was a very enjoyable experience, well run conference, I must say. And Martin and I had a great time doing our presentation there. And I did like a sort of a sponsor talk, spreading the words of the company that I work at, and yeah, especially the thing about wolves and werewolves. That's actually something in the company policy of stream that landed very well. And yeah, and overall, it was, it was a nice first step in New Year. And I hope later in the year that swift heroes can actually happen in person and that there's also some other conferences being scheduled and attended at some point in this year. Also, I want to point you to my newsletter. I moved everything from my Sunday installation, which has been working great I must say, I have no regrets with a product. But I moved it all over to get revenue because it wants to do more integrated experience with Twitter. And I am planning on doing more newsletters again. So to get back into this weekly groove of publishing some contents, because I see that, once I do things with Twitter, it really resonates with people that are on the timeline. And they get a lot of positive feedback. And one thing that I really need to keep going with my podcast, is really get this feedback, having people tell me what they like, what they don't like, stuff that they want to hear more about, especially also stuff that they don't want to hear more about. So please get in touch with me. My DMS on Twitter are always open. And I love hearing from you as my audience. So let's dive in. With the first article of this week, using decorator pattern to add architectural non intrusive analytics in Swift, Leonardo will talk about a little bit more advanced architectural topics, he will discuss cohesion and coupling while walking through some of his solutions. The most important lesson in his article that he thinks you should learn is the separation of concerns principle. In an architecture. When you start coding, it's pretty common to just put everything in one place when you start to gain experience, you will learn that it's important to separate concerns, therefore the code is easy to test and maintain. Also, it's important to split things logically because you increase the readability of your code. And when you do that, your future you or your future colleagues will be grateful. So in this article, Leonardo will explore how you can use clean architecture with a design pattern to solve an analytics problem. So he will add a way to for you to add analytics as a sort of bolt on feature by using some simple architectural principles. In the post, a very basic architecture is used to which is then evolved into a more clean, sophisticated one. And Leonardo hopes that it helps everyone to see the importance of using known patterns and protocols to make you and your colleagues life easier. What I really like about article by Leonardo is that he does quite an extensive overview of what architecture He is building, including all kinds of graphs in UML, and, and diagrams, and then actually implementing this so that you get a good grasp of how things on a more high level architectural view, translate into code. So especially if you're an iOS developer getting started, and you have to figure out a way to think about your implementation a little bit more beforehand. This article is a very nice showcase of what tools you could actually be using to make sure that you come up with a decent architecture of the implementation that you are planning. In Article the decorator pattern is used extensively. But this is just one of many design patterns that you can learn about in your journey. As a software developer, look for design patterns online, because there's so much resources available online, that you can learn from and design patterns exist for a reason, because they allow you to think on more higher level concepts. Because if you know the lingua franca of design patterns with your colleagues, you have a much easier time discussing somewhat more complex topics with each other. So it's a very worthwhile exercise to invest time in learning about this specific topic. The next article is by revenue cats written by Joshua Leibovitz. It's about migrating your Objective C SDK to Swift. Obviously, revenue cat is a well known service provider for App Store in in app purchases. And one of the things is that they of course, have been around for quite some time. And they created their SDK initially in Objective C. And like all of us, if you have a long existing code base that's written in Objective C, at some point, you want to start working towards migrating your code from Objective C to Swift. In this article, it is described how revenue cat was able to migrate their existing code base in place from Objective C to Swift by using many steps and a lots and lots of testing in between. One of the hardest challenges that needed to tackle was remaining backwards compatible with existing users of the SDK. And they use a lot of different tools to organize their plan to make sure that everything is working, that's you can track the progress and also that you can detect any issues that you run into along the way. So initially, I expected this to be an article that was very much in depth on the technicalities of migrating from Objective C to Swift. But actually, that's just one of the small things that I talked about. Because, of course, revenue cats, as an expert adopter of stock hits in iOS had to migrate to stock it too, as well. Yeah, it's a very worthwhile read. If you want to learn about ways that you can migrate your own code base from Objective C to Swift if you're still in the situation, and if you're a strictly swift developer, this is a good exercise to read this article to learn about what challenges software developers will face when they try to translate something from Objective C to Swift and it will also give you some understanding why Certain aspects of migrating source code migrated SDKs from Objective C to Swift have sometimes a little bit of a strange setup and way of implementing things, but that's just the result of the migration they had to endure with their code base. The third article is by Anton formulae tasks in Swift explained with code examples. Basically, the title assesses all tasks in Swift is part of the concurrent framework introduced at WWDC 2021. A task allows you to create a concurrent environment from a non concurrent method calling methods using async await. When working with tasks for the first time, you might recognize familiarities between dispatch queues and task. Both allow dispatching work on a different thread, but a specific priority. Yet, tasks are quite different and make our lives easier by taking away the verbosity of dispatch queues. That's a word for word read on some of the content of Antoine from the latest article, it's really great his article again, what else would you expect from Antoine but it's a very nice and detailed overview of how you can use a task in Swift with lots and lots of code examples. This is one of his top articles in my book. Again, if you asked me definitely read, and you will learn a ton just by reading this article alone. The fourth article is by Marco Heidinger. Develop a command line tool using Swift concurrency, Marco did some experimentation with the apples argument parser library. And the argument parser library makes it relatively easy to develop a command line tool is swift to library parts the command line arguments, instantiate your command type and then either execute your run method or execute a useful message. When using modern swift concurrency and use await an asynchronous function in your command line program. You will run into some issues one of them is that you get a compilation error. And in his article, he details that the argument parser framework does not support async await just yet. But he is luckily able to create a workaround for this situation by using some code snippet from shared compiler. And it allows you to add async await support yourself at the end of the article, it results in a way that you can create a command line utility in Swift that can use async await without issue and that it exits at a point in time that you actually want your command line tool to exit. So very worthwhile read because I've been using command line tools are more and more in my daily workflow, because it's just so easy to be able to create little utility in language that I know and love and still be able to use it at such a low level and integrated with all the tools that are available on a UNIX environments. The fifth and final article is by pizza freezer optimized network layer with combined efficient networking for swift UI apps. With high speeds low latency Internet being available in most places, it is easy to forget that not all of our users might be on a fast, low latency uplink when they're using our apps. You don't even have to go to some remote place to experiment patchy and unreliable connectivity. Peter lives in Hamburg, Germany. And even though high speed mobile internet is a big interest there, there are quite a few spots along some of the main overground transport links that have no or very bad connectivity. When building apps that access the internet, you should be mindful of this, he thinks and make sure you don't waste bandwidth. In this part of his article series, he wants to focus on how you can optimize network access in your apps. When you are using combine. It's a continuation of a previous article that he published. And it's a worthwhile read that allows you to learn about ways that you can optimize your network traffic and avoid fetching information multiple times. While you actually already have first a certain resource, which of course saves bandwidth. So in this article, he will discuss a number of ways that you can use combine when communicating with remote server more efficient. By using a share operator, you can share multiple subscribers to a publisher pipeline, and avoid running expensive or time consuming processes for each of those subscribers. This is particularly useful when accessing API's that have a high latency then an in process module such as your remote server or anything that involves IO. Also, he discusses the topic of debouncing, which allows you to make sure that you submit events to the network only when you need them. Because if you do quick button presses in succession, you only want to like trigger an event once so it allows you to deal more efficiently with any event that occurs in short bursts. Instead of processing every single event coming down the pipeline, you wait for a pause and only operate on the most recent event together with all the tools that he describes in his article, you will be able to use an a client and that client that can access remote servers and other asynchronous API's in a much more efficient way. There's going to be a next article in the series and there he will explore the topic of error handling and how he can handle states fled the serve responses using combine. That was the final article of this week. That's of course still done is Monday morning tweets remaining. and immediately there's a number of interesting answers on Tony's Monday morning tweet, my personal answer on his tweet was that I will be running Twitter spaces on Wednesday this week, along with Stefan, my colleague at my job. And yeah, we're just gonna dive into an interesting topic, we will discuss ways that you can stay up to date as a software developer, specifically tailored to iOS developers, of course. And yeah, I hope you can join this space, because then we can have some one on one interaction. And if you want to share something on stage, we will give you the mic and then we can have fun, hopefully awesome discussion on Wednesday 11 cet. So that's your uptime. Next to that. Ben Sherman has finished his snakes game demo, which he used to practice his Ross development skills, and Mikayla cuddle when she's done a good morning. And she's implementing sign in with Apple using Firebase on a project, also some refactoring going on. So some mess, few control needs to be brought under control again. And then your stomach is working on getting some basic functionality work in his music app. And he's hoping to get some test flyable results this week. And he's also thinking of shipping a book better for a special anniversary tomorrow. Leo Geneon is trying to keep his sanity. And that's quite hard if you look at his work list. So he's working on a presentation he's working on his MailChimp or Swift library. He's playing around with Docker and Raspberry Pi. And he's having a chat with John Morgan, and he's publishing episode with Miguel Tigges. And he's diving more into publishers and subscribers. So I think you have like two weeks worth of work, they're really ill so take care and slow down everyone once in a while man, so immediate. The next response is by Michael Tigges. himself, and he just finished a huge weekend sprint wrapping the important stuff ahead of the Okita app launch next week. This week, he is patiently waiting for the inevitable App Store rejections. So he's working through releasing and launching his app, which is great. Debug Bowditch is wishing Donny a good morning, and he's working on some HTML CSS stuff for his fellow CMS this week. And he's also learning a lot about persistent web applications and other related stuff. Francoise is still working on Rhinelander, especially on home, which is an deeplink is very happy that the first version is available for testflight embedded testing flow writes code writes that he has been sick over the past few days. So I took the chance to start a new project. So your second you start a new project. And it's another app for any developers. And it is something that will work very nicely with forge so we hope to share more details soon. And then there's no rush, my colleague at stream he just published a new article about using protocols in Swift, and he is very gracious to to provide a link to his article read the article. It didn't make the cut for this podcast episode, but that was just because he wants to limit it to five and I didn't want to put in six, but it's a great read. So definitely check out Adam Rush's blog, swiftly rush.com. And then there's Alejandro Martinez. He wants to figure out how to get a bunch of markdown files and converted in a publishable book, Donnie walls response that he uses Bondoc to convert markdown to both PDF and EPUB. And it's a bit fiddly, but once you get it tweaked to your liking, it's pretty neat. Do Nick mentioned that he is starting his way through practical core data. And Jeff Hackworth mentions that he finally got back to the quick side project that he started over a year ago. And he didn't get quite that over a version one finish line yet tell him to Jack is doing some API server updates, which of course involves having to update the client app as well. And Ahmed is back on track on his study plan for essentially by essential DEF CON. And he made a daily reminder in every weekday at three for a one hour study. Also, he's back into his fifth reading from the book Programming Fundamentals which swift four so all in all, people are just really getting along nicely, just doing some studying, getting apps ready for production and making sure that they keep in touch with each other through Twitter and letting each other know what you're working on. What I really like is that it seems that everybody is now really over the New Year's hustle that you have like after the December period, because in the second half of December, most people just drop everything. And then in January the first few weeks, you're just busy getting through all the backlog that piled up while you were away from keyboard. But now you see that people are just settling in again, getting a more relaxed thing going probably quarterly plans have been shared and have been dealt with and and laid out accordingly so that people know what they should be working on for the next couple of weeks or maybe even the next few months. So let's hope that this nice and quiet time remains productive for everybody so that we can share awesome new stuff in the coming months with each other and make sure that we're all ready for the next WWDC that is bound to be happening in I don't know sometime in June. So yeah, thank you for your time. I hope you enjoyed it. thing I shared to my podcast episodes. Again, I am revamping my newsletter and have a look at that. So you can find it on my Twitter timeline or on my website, app force one dotnet. The thing I'm going to be doing there is, of course, share all my links from my podcast episode, but also talk a little bit more in text about things I do besides my podcasting, because especially in my new role at my job, I'm just having to learn tons and tons of new skills and having all kinds of new experiences. And it would be a waste to not try and share a little bit about that. So you can imagine like, our get into video production, doing a Twitter space, what's involved with that, preparing for conference talks, and all kinds of things in that area. I will make sure that it is still relevant for iOS developers. But if it's something that interests you have a look at my newsletter because my podcast is a podcast that will remain the same. And I just want to try an experiment a little bit more through my newsletter. Thanks for your time. And have a great week and talk to you again next week. If you have any feedback, please let me know through Twitter, my DMs are open or I just had mentioned me at app force one and I'll be sure to read any feedback that you have