What I am working on
The past couple of weeks have been extremely busy - I scripted and recorded a bunch of videos about Firebase fundamentals. The first one is already live on the Firebase channel.
The other ones are in post-production and should hit the channel soon. Look forward to fresh new videos that cover topics like how to add Firebase Auth to your iOS apps, and a more detailed look at some of Firebase’s authentication providers - specifically Google Sign-In and Sign in with Apple.
Is there any topic you would like to learn more about? Drop me a line so I know which topics to prioritise!
You can tweet at me, reply to this newsletter - or send me a direct message on Twitter - my DMs are open, and I love hearing from you.
How should I configure Firebase in my SwiftUI app?
“How do you initialise Firebase in a SwiftUI application” is a frequently asked question. In the past, it was easy: add
FirebaseApp.configure() to your
AppDelegate, and you’re done. However, when Apple introduced the new SwiftUI application life cycle, they removed the need for an
I’ve written about this here and here, and answered countless StackOverflow questions. The good news is, we updated the Firebase setup flow, so it now shows you how to register an
@UIApplicationDelegateAdaptor. If you don’t use FCM or Phone Number Auth, you can also get away without an
AppDelegate - just add the configuration code to your app’s initialiser.
Protecting your apps from billing fraud and other forms of abuse
App Check is a Firebase feature that helps protect your app from abuse by attesting that incoming traffic is coming from your app and blocking traffic without valid credentials.
Want to learn how it works? Check out the codelab for iOS!
How long did that build take?
By default, Xcode shows when it last successfully built your project in the status area. But did you know it can also show how long the last build took? Here is how.
All the other Xcode settings
And if you’re wondering about all those other Xcode settings, here is how you can get a list of them, too.
What happens when you use po <somevariable>
When debugging in Xcode, many of us will use po somevariable to print the value of somevariable to the debug log. What looks like an innocent statement actually changes your application at runtime:
What’s eating up all that space on your disk, and why is the answer Xcode?
The SSD in my 2019 Intel MBP recently had bad sectors, which caused the machine to freeze completely at random intervals. Luckily, I was able to get a new machine - a 2021 M1 MBP (yay!). Unfortunately, this machine only has 512 GB of SSD (the previous had 1TB), so I constantly need to juggle Xcode versions. Here is a nifty trick from @sanguish that not only shows which apps take up all that space, but also provides granular insight into build caches, unused SDKs, and iOS Device Support files:
Passwords have been around for many years, but they come with some pretty serious security implications, let alone their UX issues. It’s no wonder “123456” and “password” are among the most popular passwords. There have been many attempts to make the use of passwords more secure, from requiring users to change their passwords on a regular basis (which didn’t actually make passwords more secure, quite on the contrary), over imposing complicated rules for passwords, to password managers (which actually are one of the best options we’ve got at the moment). None of these are perfect, and have limitations and weaknesses. Which is why a group of companies led by Apple, Google, and Microsoft committed to move beyond passwords, based on a FIDO standard.
At WWDC 2021, Apple first talked about WebAuthn as a mechanism to get rid of passwords for good (Move beyond passwords), and at WWDC 2022, they had a full session about this topic (Meet passkeys).
If you’re eager to use this in your own apps, here is a thread by @MarcoEidinger to get you started:
Getting started with security keys
For some background on FIDO, WebAuthn, and security keys (which are an important step on the way to a passwordless future), I warmly recomment this article by @Stammy. It’s a long read, but totally worth it:
The conference season is in full swing, and I’ve had the opportunity to speak at a couple of conferences already. Appdevcon in Amsterdam was a blast, and it was great to see many familiar and new faces. The slides and audio recording of my talk Building Reusable SwiftUI Components is available here.
There’s a bunch of other conferences I will speak at in the second half of the year - if you’re there, come and say hi!
- [Building SwiftUI Components @ CocoaHeads HAM (September 1st)
- Firebase & iOS Workshop @ iOSDevUK Aberystwyth (September 5th)
- Async/await in Swift @ code.talks HAM (September 15th/16th)
- Firebase @ Station F in Paris (September 19th - 23rd)
- Firebase Summit in New York City (October 18th)
👋🏻 Hi everyone!
I’ve just returned from my summer vacation, and am super excited about the next couple of weeks and months. The second half of the year usually is filled with some events that I am personally really looking forward to.
Apple’s annual launch of the next version of iOS is one of them, and you can already feel the excitement in the developer community about all the new APIs we will be able to use in our apps (if you’re lucky enough to be able to support the latest release). What are you most looking forward to? Let me know by hitting the reply button!
Firebase Summit is another event I am excited about. Not just because we will finally be able to show you all the cool things that we’ve been working on in the past couple of months since Google I/O, but also because it gives me the opportunity to meet many of you in person. This year, Firebase Summit will take place in New York City, at Pier 57. This is a fantastic venue, close to the Google office in New York City.
You can register here, but be quick - there’s a limited number of spots at the venue, and they will fill up quickly!
Will I see you there? Don’t be shy and say hi! if you attend - I look forward to meeting you :-)
Thanks for reading,Peter 🔥