Introduction to Firebase Local Emulator Suite
What if I told you there is a version of Firebase that you can run on your own machine?
Yes, that's right - the Firebase Local Emulator Suite allows you to run (most of) your Firebase backend on you local development machine. This is great for development and testing. Since everything happens locally, the turn-around times are a lot faster (in particular when deploying Cloud Functions).
Speaking of which, if you're interested in learning more about Cloud Functions, the Emulator suite, and maybe even some AI/ML stuff, attend Appdevcon 2023 in Amsterdam and join our workshop Supercharge your mobile apps with Cloud Functions for Firebase! Zamzam and I will teach you how to build Cloud Functions (and call them from Android and iOS), run them on the local Emulator, and deploy them to your Firebase project.
If you can't make it to Amsterdam, check out Your quickstart to the Firebase Emulator Suite, in which Firebase Engineer Chris Thompson walks you through the process of setting up and using the Emulator.
Swift Community Awards – Hacking with Swift
The Swift Community Awards celebrate the developers, conferences, companies, tools, SDKs, and more that make the Swift community unique.
I love these awards, as they provide a unique perspective at what the community deemed important - all nominations and all awards are decided by the community members.
The categories this year are:
- Best conference
- Best design tool
- Best third-party service
- Best developer tool
- Best open-source project
- Most inspiring indie app
- Most inspiring presentation
- Rising star
So take a few minutes of your time today, and nominate your favourites!
Automatic grammar agreement
"One item(s) selected" - I am sure you've seen this in many apps before. Now, I know what you're thinking - "developers who do this in their apps are just lazy". And that might be true if you only need to support one language, and showing the proper inflection is a matter of a simple ternary expression. But what if you need to support multiple languages? And what about languages in which both the subject and verb can change in a subject-verb agreement?
In his first ever YouTube Short, Paul demonstrates a little-known feature called Automatic Grammar Agreement that has been around since iOS 15. To learn more about this, check out the What's new in Foundation WWDC 2021 talk (at the 27:02 mark), or this Kodeco tutorial: SwiftUI Localization Tutorial for iOS: Getting Started
Swift Evolution proposals in Alfred (and Raycast!)
When I read Ole's blog post about browsing Swift Evolution proposals in Alfred, I felt a light sting of jealousy. You see - I've been a long-time Alfred user, but switched to Raycast a while ago.
"Wouldn't it be nice if there was a Raycast command for this", I thought (and I am not ashamed to admit I briefly considered building one myself). But it turns out there actually is one already, and it even allows you to read the proposals in the Raycast window - no need to jump to the browser.
Handling status bar color scheme and visibility in SwiftUI | Daniel Saidi
Daniel has been busy implementing a library for offset tracking, and stretchable and sticky headers for SwiftUI scroll views.
One challenge that you will be facing when using headers is the tint color of the status bar. Depending on the color theme of the system (light or dark), this might lead to undesired effects.
Daniel discusses a couple of strategies to deal with this, and ends up implementing a view modifier to encapsulate the following behaviour:
- Initially hide the status bar until the scroll view is scrolled
- The status bar should then become visible until the scroll view is scrolled back to its starting position * The status bar should also not show when the scroll view is pulled down and the header stretched out
AI and ML
How does GPT-4 stack up against Claude?
Not a single week seems to pass by without someone releasing a Large Language Model (LLM). To make it easier to compare them, Nat Friedman and team have been working on an AI comparison playground at https://nat.dev/compare.
Seeing the results side-by-side is pretty interesting. I also noticed there is a huge difference in speed, so if this is something that's important for your app, this is a great tool.
Not By AI Badges — A Badge for Your AI-Free Content
With more and more content being produced by or with the help of AI, it might be time to mark your hand-crafted, AI-free content using an appropriate badge.
Before we know it, sending someone an email that you actually wrote yourself will have the same significance as sending someone a hand-written letter...
h/t to Stammy for digging this out!
Modify a Value During iOS Debugging in Xcode
Did you know that you can modify the value of a variable while debugging in Xcode? Me neither. And who would blame us, because this isn't exposed in the UI.
Marco shows how you can do this on the the debugger command line using the
expression command. Super handy for those cases when you're deep in a debugging session only to find out that you forget to set the correct state.
expression foo = "bar", and you've saved yourself some precious time.
I've used similar features in other IDEs in the past, and I still find it shocking that Xcode is lagging behind in so many areas. In this particular case, it is "just" a case of exposing this feature on the UI.
Apple Music Classical
Apple announced the release of Apple Music Classical (see Apple Music Classical will start streaming on March 28th).
If you're wondering why a company would want to have not one, but two music apps, check out Jessie Char's thread on Twitter. She's a classically trained cellist, composer, former Apple employee, and CEO of a design studio specialising in icon and UI design, so she's in a unique position to explain this in detail.
I wish Spotify would take this to heart and extract their podcasts and audio books into separate apps... In fact, they seem to have considered that - in this Decoder episode at the 15:27 mark, Spotify CTO and CPO Gustav Söderström and Alex Heath discuss exactly that.
Introducing Zed: A high-performance, multiplayer code editor. Now in beta.
One should think there are enough editors But still people build new editors Heck, they even found companies to build text editors!
If you're interested in diving deeper into how Zed works, check out Leveraging Rust and the GPU to render user interfaces at 120 FPS and How CRDTs make multiplayer text editing part of Zed's DNA
How to Yubikey: a configuration cheatsheet
If you're not using second factor authentication (2FA) for your most sensitive services, you should stop reading and enable it now. Ideally based on a physical token, such as a Yubikey.
If you're already using a Yubikey (they come in different shapes and sizes), you might think that it's merely acting as an additional factor in your authentication flow for services like Gmail, GitHub, your bank, etc.
But they can do so much more!
In this article, klmille shows a couple of cool things you can do with Yubikeys that go beyond 2FA:
- Generating time-based passwords
- Acting as a FIDO compliant second factor
- Generating static passwords on touch
- Serving as a smartcard
- Encrypting your disk
- ... and more
The Lisa: Apple's Most Influential Failure
Despite some visionary features, such as the graphical user interface (which was a novelty - back then, most computers only had a text-based interface), the Lisa (named after Steve Jobs' daughter) was a failure - at face value.
But, as this article points out, "without the Lisa, there would have been no Macintosh—at least in the form we have it today—and perhaps there would have been no Microsoft Windows either."
If you're interested in reading the original source code for the Lisa, including the system and application software, check out this link.
This week was a no-meetings week at Firebase, which was nice (I got a lot done) and strange (not seeing your colleagues face to face, just on chat) at the same time.
I did have a video call with Zamzam, though - we're working on a workshop about Cloud Functions that we will deliver at Appdevcon (May 9 - 12 in Amsterdam). If you want to learn how to Supercharge your mobile apps with Cloud Functions for Firebase, make sure to attend this conference. One of the things we will teach you is how to run Firebase on your local machine!
Next week, I will be in Oslo to deliver my talk "Building Reusable SwiftUI Components" at Apprise (March 23rd). If you're there, you can win an autographed copy of my book by liking and retweeting this tweet.
Thanks for reading - and if you see me at a conference, do say hi!Peter 🔥