<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Mohammad Azam on Medium]]></title>
        <description><![CDATA[Stories by Mohammad Azam on Medium]]></description>
        <link>https://medium.com/@azamsharp?source=rss-2300266301b3------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*Wfeql4CDzQz6fq15jGfmQA.png</url>
            <title>Stories by Mohammad Azam on Medium</title>
            <link>https://medium.com/@azamsharp?source=rss-2300266301b3------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 02:00:40 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@azamsharp/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com" rel="hub"/>
        <item>
            <title><![CDATA[Working with AGENTS.md: What I Learned]]></title>
            <link>https://azamsharp.medium.com/working-with-agents-md-what-i-learned-640c8fb7a5b4?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/640c8fb7a5b4</guid>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[ai-agent]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[xcode]]></category>
            <category><![CDATA[agentic-ai]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Thu, 12 Nov 2026 19:51:56 GMT</pubDate>
            <atom:updated>2026-11-12T20:47:50.815Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sNSkGk02DvA2vvGJiQs4bg.png" /></figure><p>An AGENTS.md file contains the conventions and guidelines that you want your AI coding agent to follow. It is a living document, which means you can update it as your project evolves.</p><p>The file is usually placed at the root of your project. You can also have multiple AGENTS.md files, each containing instructions for a particular directory or module. But I think it is a good idea to start with a single file and add more when needed.</p><p>In this article, I am going to use Codex integrated into Xcode to see how it follows the instructions defined in AGENTS.md. I will also explore what happens when we update those instructions during an active conversation and whether Codex can apply new conventions to existing code.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/408/0*cCVMELHVkTFRw6wZ.png" /></figure><p><a href="https://azamsharp.school/swiftui-architecture-book.html"><strong>Get the book</strong></a></p><h3>Creating Our First AGENTS.md File</h3><p>Let’s start with a simple example. Create an AGENTS.md file at the root of your Xcode project and add the following instruction.</p><pre># Foundation</pre><pre>- Every function should follow the snake_case naming convention.</pre><p>Yes, I know this is silly because Swift does not use snake_case for function names. It uses camelCase. But I wanted to see whether the agent would follow my guidelines even when they were different from the standard Swift conventions.</p><p>I opened a new conversation in Xcode using Codex and entered the following prompt:</p><blockquote><em>Write a function in ContentView so it can toggle isOn state.</em></blockquote><p>Here is the generated code:</p><pre>struct ContentView: View {<br>    @State private var isOn = false<br>private func toggle_is_on() {<br>        isOn.toggle()<br>    }<br>    var body: some View {<br>        VStack {<br>            Image(systemName: &quot;globe&quot;)<br>                .imageScale(.large)<br>                .foregroundStyle(.tint)<br>            Text(&quot;Hello, world!&quot;)<br>        }<br>        .padding()<br>    }<br>}</pre><p>As you can see, Codex followed the instructions from AGENTS.md and created a function called toggle_is_on. Of course, this is not following the standard Swift naming convention, so I updated the file to use camelCase instead.</p><pre># Foundation<br>- Every function should follow the camelCase naming convention.</pre><p>Since I updated the file during an active conversation, I asked Codex to reread it and update the existing code to follow the new guidelines. The expected result was to rename toggle_is_on to toggleIsOn.</p><p>One thing to keep in mind is that AGENTS.md is not a compiler or a rule enforcement system. It provides instructions that compatible AI coding agents can follow, but that does not mean the agent will always follow them. You still need to review the generated code.</p><p>Also, you don’t have to explain basic Swift syntax or standard naming conventions in AGENTS.md. Modern coding assistants already understand Swift and SwiftUI. I think the real value of this file is communicating architectural decisions and conventions that are specific to your project.</p><h3>Adding Architectural Guidelines</h3><p>In my SwiftUI applications, I prefer using the MV (Model View) pattern. Views manage their own presentation state, stores manage shared application state, and services handle operations such as networking. I want Codex to follow these conventions instead of introducing additional architectural layers that I don’t need.</p><p>Here is an example of the guidelines I use:</p><pre>## Core Principles<br>1. No ViewModel classes. Views hold their own<br>   presentation state.<br>2. Use @State for local state, @Binding for<br>   parent-owned state, and @Observable for<br>   shared observable state.<br>3. Container views (*Screen) access stores.<br>   Child views (*View) receive data through<br>   parameters.<br>4. Stores are @Observable @MainActor classes<br>   with private(set) on mutable state.<br>   Commands are methods and queries are<br>   computed properties.<br>5. Services are stateless structs with no<br>   mutable stored properties.<br>6. Inject stores using .environment() at<br>   the narrowest useful scope.<br>7. Prefer @Observable and @Environment over<br>   ObservableObject and @EnvironmentObject<br>   for new code.<br>8. When a view exposes three or more event<br>   closures, consolidate them into an<br>   enum-based event pattern.<br>   Reference:<br>   References/EnumBasedEventPattern.md</pre><p>These are just some of the conventions I prefer when building SwiftUI applications. Your guidelines may be different depending on your architecture and the requirements of your project.</p><p>Notice the last instruction about grouping multiple view events into an enum. Instead of explaining the entire pattern inside AGENTS.md, I referenced another file called References/EnumBasedEventPattern.md. This file contains an example of how to implement the pattern, so the agent can read it when needed.</p><p>I think this is a good approach because it allows us to keep AGENTS.md relatively small while providing detailed examples in separate files.</p><h3>Does Codex Read AGENTS.md on Every Request?</h3><p>One question I had was whether Codex automatically rereads AGENTS.md every time I submit a new prompt. To test this, I added the following instruction:</p><pre>## IMPORTANT<br>- Make sure to read the AGENTS.md file on each<br>  coding assistant request/prompt and comply<br>  with the latest guidelines and conventions.</pre><p>Of course, just because I added this instruction does not mean Codex will always reread the file. If the agent has not loaded the latest version, it may not even know that the instruction exists. But I wanted to see how it would behave.</p><p>I also added another naming convention:</p><pre>9. Swift struct names must begin with the letter S.</pre><p>Yes, another silly convention. But that was the whole point of the experiment. I wanted to see whether Codex would follow instructions that were different from normal Swift conventions.</p><p>I asked Codex to add a function to ContentView to toggle the isLightOn state. Codex inspected the project guidelines and recognized the new naming convention, but it did not rename ContentView to SContentView.</p><p>Instead, it responded:</p><blockquote><em>The latest project rules add an S prefix convention for Swift structs. This request doesn’t introduce or rename a struct, so I’ll limit the edit to the requested state and function inside the existing ContentView.</em></blockquote><p>This was interesting because Codex clearly understood the convention but decided not to apply it to the existing struct. When you think about it, this makes sense. I only asked it to add a function, not rename existing types. In most cases, this is actually the behavior we want because changing unrelated code can introduce unnecessary problems.</p><p>But what would happen if Codex had to create a new struct?</p><h3>Testing New SwiftUI Views</h3><p>I asked Codex to create a new SwiftUI view that displays a Toggle for enabling dark mode. Here is the code it generated:</p><pre>struct SettingsView: View {<br>    @State private var isDarkModeEnabled = false<br>var body: some View {<br>        Form {<br>            Toggle(<br>                &quot;Dark Mode&quot;,<br>                isOn: $isDarkModeEnabled<br>            )<br>        }<br>        .preferredColorScheme(<br>            isDarkModeEnabled ? .dark : .light<br>        )<br>    }<br>}</pre><p>Codex created SettingsView, which actually follows the naming convention because the name already begins with the letter S. Initially, I overlooked this and expected it to generate SSettingsView. But my instruction only required struct names to begin with S, not to add an additional S prefix.</p><p>I started another conversation and explicitly asked Codex to read AGENTS.md and follow all project naming conventions. This time, it created SDarkModeView, which also satisfied the rule.</p><p>Both results were valid, although the naming patterns were different. This made me realize that if I wanted every struct to have a specific prefix, I should have written a more precise instruction. For example, I could have required every Swift struct name to begin with the prefix AZ instead of simply requiring the first letter to be S.</p><p>This made me wonder whether we always need to remind Codex to read AGENTS.md. To test this, I started another request without mentioning the file or any naming conventions.</p><p>My prompt was:</p><blockquote><em>Create a SwiftUI view that displays a list of books.</em></blockquote><p>Codex inspected the project conventions and responded:</p><blockquote><em>The project requires every Swift struct name to begin with S, so I’ll follow that convention for both the book model and views.</em></blockquote><p>It then created a view called SBookListView. Once again, Codex followed the convention, this time without me explicitly asking it to reread AGENTS.md.</p><p>At this point, Codex had generated SettingsView, SDarkModeView, and SBookListView. All three names satisfied the convention because they began with S. However, the results also showed that my instruction was somewhat ambiguous. It did not specify whether Codex should add a prefix or simply ensure that the name started with the required letter.</p><p>But I wanted to test one more thing. What happens if I change the naming convention during the same conversation?</p><h3>Updating AGENTS.md During an Active Conversation</h3><p>I updated the naming convention from requiring an S prefix to requiring a D prefix.</p><pre>10. Swift struct names must begin with the letter D.</pre><p>Without starting a new conversation, I asked Codex to create a new view called HelloWorldView that displays Hello World.</p><p>Here is the generated code:</p><pre>import SwiftUI<br>struct DHelloWorldView: View {<br>    var body: some View {<br>        Text(&quot;Hello World&quot;)<br>    }<br>}<br>typealias HelloWorldView = DHelloWorldView<br>#Preview {<br>    HelloWorldView()<br>}</pre><p>Codex created DHelloWorldView instead of SHelloWorldView, which means it was following the updated convention. But notice that it also introduced a typealias.</p><p>My prompt specifically asked for a view called HelloWorldView, while AGENTS.md required every Swift struct to begin with D. Codex tried to satisfy both requirements by creating DHelloWorldView and exposing it as HelloWorldView through a typealias.</p><p>Technically, this works, but I don’t think I would want the agent creating typealiases just to satisfy naming conventions. I would rather have it use the correct name directly.</p><p>What I found even more interesting was the activity log in Xcode. Codex explicitly mentioned that it was going to reread the project conventions, and the log showed AGENTS — 19 lines read. It then explained that the current convention required every Swift struct to begin with D, and the project built successfully.</p><p>So, in this experiment, Codex did read the updated AGENTS.md file and followed the new convention without requiring a new conversation. This does not mean it will always reread the file on every request, but at least we know it can pick up changes during an active conversation.</p><h3>Can AGENTS.md Update Existing Code?</h3><p>There was still one thing that bothered me. If the latest convention requires every Swift struct to begin with D, why didn’t Codex update existing structs such as ContentView, SettingsView, or SBookListView?</p><p>My initial thought was that Codex was limiting its changes to the current request. So I decided to make the instructions more explicit.</p><p>I updated AGENTS.md with the following guidelines:</p><pre>## IMPORTANT<br>- Read AGENTS.md at the beginning of every coding<br>  request and follow the latest guidelines and conventions.<br>- Apply all conventions to both new and existing code.<br>- Before implementing a request, inspect the relevant<br>  existing code for violations of these conventions.<br>- Update existing components, structs, functions, and<br>  other declarations to comply with the latest conventions,<br>  even if they were created before the rules were added.<br>- When renaming or modifying existing code, update all<br>  affected references to prevent compilation errors.<br>- After making changes, build the project and resolve<br>  any errors introduced by the changes.</pre><p>I thought this would be enough because I was explicitly telling Codex to update existing code, even if it was created before the new rules were added.</p><p>I asked Codex to add a function to ContentView to toggle the isLightOn state. Codex inspected the code and discovered that the function already existed.</p><pre>private func toggleIsLightOn() {<br>    isLightOn.toggle()<br>}</pre><p>It responded that no code changes were needed, built the project successfully, and finished. But it still did not rename ContentView to DContentView.</p><p>Maybe the problem was that the function already existed, so Codex decided there was nothing to do. To eliminate that possibility, I tried another prompt:</p><blockquote><em>Add a new @State property called isLoading to ContentView.</em></blockquote><p>This request required an actual code change. I wanted to see whether Codex would also rename ContentView to DContentView to comply with the latest convention.</p><p>But it didn’t. Codex handled the requested change without performing the broader naming updates.</p><p>At this point, I had explicitly instructed Codex through AGENTS.md to update existing code, but it was still not doing it during normal feature requests. I wanted to see whether it would behave differently if I asked it to perform a project audit.</p><h3>Asking Codex to Audit the Entire Project</h3><p>Instead of asking Codex to add another feature, I entered the following prompt:</p><blockquote><em>Audit the entire project against AGENTS.md. Fix all violations, including renaming existing Swift structs to begin with D. Update all references and build the project.</em></blockquote><p>And this time, it worked! Codex updated the existing structs to follow the naming convention.</p><p>I think this was one of the most interesting results from my experiments. I had already instructed Codex through AGENTS.md to apply conventions to both new and existing code, but it did not perform the broader updates when I asked it to add a feature. When I explicitly asked it to audit the project, it performed the refactoring.</p><p>This suggests that Codex treats the instructions in AGENTS.md as guidelines for completing the current task. Even when those guidelines mention updating existing code, it may still limit its changes to the work you explicitly requested.</p><p>One thing to keep in mind is that AGENTS.md does not automatically enforce conventions across your entire project. It provides instructions to the agent, but if you want existing code throughout your application to follow new conventions, you may need to explicitly ask for that work.</p><p>Also, just because your project builds successfully does not mean it follows all the conventions defined in AGENTS.md. A successful build tells us that the code compiles, not whether it follows your architectural decisions or naming conventions.</p><h3>What Did I Learn?</h3><p>After running these experiments, I learned that Codex can follow conventions defined in AGENTS.md, even when those conventions go against standard Swift practices. I also found that Codex can reread the file during an active conversation and pick up updated instructions without requiring a new conversation.</p><p>But the results were not always consistent. In one experiment, Codex created SettingsView instead of SSettingsView. In another experiment, it correctly created SBookListView. It also introduced a typealias when trying to satisfy both my naming convention and the name I requested in the prompt.</p><p>Another important observation was that Codex considers the scope of the task. When I asked it to add a function or a state property to ContentView, it did not rename the existing struct, even though my AGENTS.md explicitly instructed it to update existing code. But when I asked it to audit the entire project, it performed the refactoring.</p><p>Now, these are just my observations from a few experiments. I am not saying that Codex will behave exactly the same way every time. But I think they demonstrate why we still need to review the code generated by AI agents instead of assuming they will always follow our guidelines.</p><h3>Do We Really Need to Document Everything in AGENTS.md?</h3><p>One thing I have been exploring recently is whether we really need to document every architectural convention in AGENTS.md.</p><p>For example, let’s say I scaffold my SwiftUI application myself. I create the models, stores, views, function signatures, and comments describing what each function should do. If my project already contains working examples of the architectural patterns I prefer, shouldn’t the AI agent be able to infer those patterns from the existing code?</p><p>I think it should be able to, as long as it examines the relevant code and has enough context to understand the patterns.</p><p>This raises an interesting question. If the code itself communicates the architecture, how much additional value does AGENTS.md provide?</p><p>For example, if my project already uses the MV pattern, contains @Observable stores, and uses enum-based events for reusable views, do I need to repeat all of those conventions in AGENTS.md? Or can the agent figure them out by looking at the existing code?</p><p>This is something I have been researching, and I plan to explore it further through experiments. For now, I prefer keeping AGENTS.md focused on guidelines that may not be obvious from the existing codebase.</p><h3>Final Thoughts</h3><p>Keep in mind that AGENTS.md should reflect your own guidelines and architectural preferences. If you’re working with a team, it is a good idea to discuss these conventions and make sure everyone is on the same page.</p><p>You can include guidelines related to architecture, testing, deployment, third party libraries, error handling, and other aspects of your application. You can also reference existing code files or documentation to help the agent understand how a particular pattern should be implemented.</p><p>My recommendation is to start small. You don’t need to create a large AGENTS.md file before writing your first line of code. As you work with your AI coding agent, you may notice certain patterns or conventions that it does not follow. Those are good candidates to add to your AGENTS.md file.</p><p>But don’t assume that adding a rule guarantees the agent will follow it every time. And if you want the agent to update existing code to follow new conventions, don’t assume it will automatically do that either. As my experiments showed, you may have to explicitly ask it to audit and update the project.</p><p>The goal is not to write as many instructions as possible. The goal is to provide enough guidance so the agent can work within the architecture you have defined. And most importantly, just because AI can generate code does not mean we should stop understanding the code it produces.</p><h3>SwiftUI Architecture Book</h3><p>If you’re looking for an AGENTS.md file for your SwiftUI projects, check out my SwiftUI Architecture: Patterns and Practices for Building Scalable Applications book.</p><p>The book covers practical architectural patterns for building SwiftUI applications that remain maintainable as they grow. It also comes with a downloadable AGENTS.md file that you can use as a starting point for your own projects.</p><p><a href="https://azamsharp.school/swiftui-architecture-book.html">Get the SwiftUI Architecture Book</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=640c8fb7a5b4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Learning to Learn in the Age of AI]]></title>
            <link>https://azamsharp.medium.com/learning-to-learn-in-the-age-of-ai-11116223d788?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/11116223d788</guid>
            <category><![CDATA[chatgpt]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[claude]]></category>
            <category><![CDATA[vibe-coding]]></category>
            <category><![CDATA[coding]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Sat, 07 Nov 2026 02:24:00 GMT</pubDate>
            <atom:updated>2026-11-07T02:24:00.371Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZDB5x7AhyDGTdrcy2Ay8YA.png" /><figcaption>Learning to Learn in the Age of AI</figcaption></figure><p>I started learning programming back in the early 90s. The World Wide Web had just been introduced, but it would still be a few years before I had access to the internet.</p><p>Luckily, books were available, and I spent most of my time reading programming books and manually typing code, one instruction at a time, into the editor. One of the first programming languages I learned was GW BASIC. I still remember creating a simple program that displayed a face that would switch between happy and sad.</p><p>A few years later, I finally got access to the internet, and a few years after that, Google arrived. Technology was advancing rapidly, but developers still had to struggle to find and implement solutions.</p><p>For example, imagine you were building an application that displayed a map, and you wanted to cluster different markers together. You would have to read documentation, search Stack Overflow, or explore other online resources to figure out how to implement it.</p><p>Sometimes, you would find the exact answer you were looking for. Other times, you would find something similar and have to think through how to apply that solution to your particular situation.</p><p>Fast forward to today, and AI can generate an entire implementation in just a few seconds. This is great because you save a lot of time and suddenly become a 10X developer. But at the same time, you may not have struggled at all. All it took was a single prompt, and your work was done.</p><p>But if AI does all the work, what exactly are we learning?</p><p>I have been teaching in one form or another since before 2002, and one thing I strongly believe is that if you are not struggling, you are not learning. This is especially true when you are trying to learn something new.</p><p>When I was teaching at a physical campus, I would always tell my students to break down a problem into smaller tasks. For each task, give yourself 15 to 20 minutes of pure struggle before asking for help.</p><p>That is when real learning happens.</p><p>You might try nine different approaches, and none of them work. Finally, on your tenth attempt, you find a solution. But you did not fail nine times. You discovered nine different approaches that did not work.</p><p>As Thomas Edison is often quoted as saying:</p><blockquote><em>I have not failed. I’ve just found 10,000 ways that won’t work.</em></blockquote><p>Today, AI has made it easier than ever to avoid that struggle. Even worse, some developers have stopped reviewing AI generated code. They simply assume that because AI wrote the code and it works, it must be good.</p><p>Unfortunately, my experience has been that while AI is very good at generating code, it does not always account for the long term consequences of its decisions. It can produce a working implementation without considering how that implementation will affect the architecture, maintainability, or future development of the application.</p><p>Generating code is not the same as engineering software.</p><p>So, should we stop using AI?</p><p><strong>No</strong>.</p><p>AI is a powerful technology, but with great power comes great responsibility. We should use AI to enhance and amplify our learning instead of replacing it.</p><p>Instead of asking AI to generate the complete solution, ask it to point you toward the documentation for the framework you are trying to learn. You can even explicitly tell AI not to provide a solution, but instead to share relevant code samples from the documentation.</p><p>You can also ask for a hint rather than working code. That hint might give you just enough information to investigate further and move one step closer to solving the problem yourself.</p><p>There is also an important difference between using AI to become more productive and using AI to become a better programmer.</p><p>We often measure the success of AI by how much time it saves us. But when it comes to learning, saving time should not always be the goal. Sometimes, spending an hour understanding a problem is more valuable than solving it in five minutes.</p><p>One analogy I find helpful is going to the gym. Imagine hiring a personal trainer, but instead of exercising yourself, you let the trainer lift all the weights while you sit on the sidelines.</p><p>No matter how much your trainer exercises, you are not going to lose weight or build muscle. Your trainer might get stronger, but you won’t.</p><p>The same idea applies to your brain.</p><p>Your brain also needs exercise, and one way to exercise it is by working through problems yourself. You need to think critically about different scenarios, explore possible solutions, and understand how your decisions affect the final implementation.</p><p>This does not mean you should struggle with everything. There is a difference between productive struggle and unnecessary frustration. Spending hours dealing with a configuration issue may not teach you much, but spending time understanding why your application has a race condition can make you a better developer.</p><p>The goal is not to make programming unnecessarily difficult. The goal is to make sure we are still learning.</p><p>The next time you are working on a problem, break it down into smaller tasks. Spend 15 to 20 minutes working through each task before waving the white flag and asking AI for help.</p><p>During that time, you can still use AI to look up references, documentation, code samples, or even ask for hints. Just resist the temptation to ask it to generate the complete solution.</p><p>Those 15 to 20 minutes might feel frustrating, especially when you know AI could solve the problem in seconds. But that struggle is an investment in yourself.</p><p>When I was learning GW BASIC, I spent hours writing simple programs and figuring out why things did not work. Today, AI could generate those same programs in seconds.</p><p>But I don’t consider those hours wasted. They taught me how to think, experiment, solve problems, and keep going when things did not work.</p><p>I am not suggesting that we should stop using AI or go back to the way we programmed in the 90s. I am suggesting that we should be intentional about how we use AI, especially when our goal is to learn.</p><p>There is a great quote that captures this idea perfectly:</p><p>“<em>You can outsource your thinking, but you cannot outsource your understanding.</em>”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/408/0*tXfV2261ePd03fGD.png" /></figure><p><a href="https://azamsharp.school/swiftui-architecture-book.html"><strong>Get the book</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=11116223d788" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Implementing Server-Side Sorting in SwiftUI]]></title>
            <link>https://azamsharp.medium.com/implementing-server-side-sorting-in-swiftui-62bd82feb8ec?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/62bd82feb8ec</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[ios-development]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[rest-api]]></category>
            <category><![CDATA[swift-programming]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Sat, 17 Oct 2026 15:32:10 GMT</pubDate>
            <atom:updated>2026-10-17T15:32:10.225Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jwy8KKO2QPn34sed9sAQ2w.png" /></figure><p>When building applications, it is common to display a list of items and allow users to sort them based on different criteria. For example, in a hotel booking application, users may want to sort hotels by price or guest ratings.</p><p>There are different ways to implement sorting. One approach is to fetch all the records from the server and sort them locally on the client. This works fine for smaller datasets, but as the number of records grows, fetching everything just to sort it is not a good idea. A better approach is to let the server handle sorting and return the results in the requested order.</p><p>In this article, we will learn how to implement server-side sorting using Express.js and SwiftUI. We will start by building an API that supports different sorting options through query parameters. Next, we will implement the SwiftUI client using the @Observable macro to manage our hotel data. Finally, we will create a sorting interface that allows users to select, clear, and confirm their sorting preferences.</p><p>Let’s get started!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/408/0*Pg47svkS0d111UA0.png" /></figure><p><strong>Patterns and Practices for Building Scalable Applications</strong></p><p>A practical guide to building SwiftUI apps that stay clean as they grow.</p><p><a href="https://azamsharp.school/swiftui-architecture-book.html"><strong>Get the book</strong></a></p><h3>Building the Sorting API with Express.js</h3><p>These days, you have countless options when it comes to implementing a server. Even in the Swift ecosystem, you have frameworks like Vapor and Hummingbird. My personal favorite is Express.js, mainly because I have taught it for a long time and I also enjoy the dynamic nature of JavaScript.</p><p>One thing I like about using JavaScript on the server is that I don’t have to create separate DTO objects for every response. I can simply return anonymous objects. I personally like this flexibility.</p><p>For our hotel application, we will implement an API endpoint that allows clients to sort hotels based on different criteria, such as price and guest ratings. The client will specify the sorting option using a query string parameter, and the server will be responsible for sorting the results before returning them.</p><p>Below, you can find the implementation of the /api/hotels route, which supports different sorting options.</p><pre>app.get(&quot;/api/hotels&quot;, (req, res) =&gt; {<br>// get the sort options <br>    const { sort } = req.query<br>    // hotels is a hard-coded list <br>    const sortedHotels = sortHotels(hotels, sort)<br>    res.json(sortedHotels)<br>})<br>const sortHotels = (hotels, sort) =&gt; {<br>    switch (sort) {<br>        case &quot;priceLowToHigh&quot;:<br>            hotels.sort((a, b) =&gt; a.price - b.price)<br>            break<br>        case &quot;priceHighToLow&quot;:<br>            hotels.sort((a, b) =&gt; b.price - a.price)<br>            break<br>        case &quot;guestRating&quot;:<br>            hotels.sort((a, b) =&gt; b.guestRating - a.guestRating);<br>            break<br>    }<br>    return hotels <br>}</pre><p>The query string parameter determines how the hotels are sorted. For example, <a href="http://localhost:8080/api/hotels?sort=priceLowToHigh">http://localhost:8080/api/hotels?sort=priceLowToHigh</a> will return hotels sorted by price in ascending order, from lowest to highest.</p><p>Now that our server is working as expected, we can move on to implementing the SwiftUI client.</p><h3>Building the SwiftUI Hotel App</h3><p>We will start by implementing our HotelStore, which will be responsible for managing the state of hotels along with the business and domain logic associated with them.</p><blockquote><em>Unlike traditional View Models, you don’t need to create a separate HotelStore for each screen. HotelStore is designed around the bounded context of hotel management and can be shared across multiple screens that work with hotel-related entities and operations.</em></blockquote><p>The implementation of HotelStore is shown below:</p><pre>@Observable<br>class HotelStore {<br>    <br>    private(set) var hotels: [Hotel] = []<br>    let httpClient: HTTPClient<br>    <br>    init(httpClient: HTTPClient) {<br>        self.httpClient = httpClient<br>    }<br>    <br>    func loadHotels(sortOption: SortOption? = nil) async throws {<br>        let resource = Resource(url: Constants.URLs.hotels(sort: sortOption), responseType: [Hotel].self)<br>        hotels = try await httpClient.fetch(resource: resource)<br>    }<br>}</pre><p>HotelStore has a dependency on HTTPClient, which is responsible for performing network requests. The loadHotels function also accepts an optional SortOption, allowing us to construct the appropriate URL based on the selected sorting option.</p><p>The Constants.URLs.hotels function is responsible for constructing the URL with the necessary query string parameters. In a future article, we will extend this function to support filtering and pagination.</p><p>Inside our SwiftUI view, we can access HotelStore through the environment.</p><blockquote><em>Another option is to pass HotelStore as a dependency through the initializer. I personally prefer using the environment because I often end up using the same store across multiple screens. Passing the store through the initializer of every screen can become cumbersome.</em></blockquote><p>The implementation of HotelListScreen is shown below:</p><pre>struct HotelListScreen: View {<br>    <br>    @Environment(HotelStore.self) private var hotelStore<br>    @State private var showSortSheet: Bool = false<br>    <br>    @State private var sortOption: SortOption?<br>    <br>    var body: some View {<br>        List {<br>            <br>            HStack {<br>                Spacer()<br>                Button(&quot;Sort&quot;) {<br>                    showSortSheet = true<br>                }<br>            }<br>            <br>            ForEach(hotelStore.hotels) { hotel in<br>                HotelCellView(hotel: hotel)<br>            }<br>        }<br>        .sheet(isPresented: $showSortSheet, content: {<br>            SortView(initialSelection: sortOption, onDone: { option in<br>                sortOption = option<br>                Task { await loadHotels() }<br>            }).presentationDetents([.fraction(0.25)])<br>        })<br>        .task {<br>            await loadHotels()<br>        }.navigationTitle(&quot;Hotels&quot;)<br>    }<br>    <br>    private func loadHotels() async {<br>        do {<br>            try await hotelStore.loadHotels(sortOption: sortOption)<br>        } catch {<br>            print(error.localizedDescription)<br>        }<br>    }<br>}</pre><p>You might be wondering why we pass sortOption to the loadHotels function instead of creating a separate function for sorting. You can definitely take that approach, but I personally prefer this design, which is inspired by the Sequelize ORM in JavaScript.</p><p>The idea is simple. You can call loadHotels without passing any options to fetch the default set of hotels (limited to 10 records by default), or you can provide options to customize the results. As we add more features, the same function will support sorting, filtering, and pagination without requiring separate functions for each operation.</p><p>The user selects the sorting option through SortView. The implementation is shown below:</p><pre>struct SortView: View {<br>    <br>    @State private var selectedSortOption: SortOption?<br>    @Environment(\.dismiss) private var dismiss<br>    <br>    let onDone: (SortOption?) -&gt; Void<br>    <br>    init(initialSelection: SortOption? = nil, onDone: @escaping (SortOption?) -&gt; Void) {<br>        _selectedSortOption = State(initialValue: initialSelection)<br>        self.onDone = onDone<br>    }<br>    <br>    var body: some View {<br>        VStack {<br>            <br>            HStack {<br>                Button(&quot;Close&quot;) {<br>                    dismiss()<br>                }<br>                <br>                Spacer()<br>                <br>                Button(&quot;Clear&quot;) {<br>                    selectedSortOption = nil<br>                }<br>                <br>            }.padding([.bottom], 10)<br>            <br>            ForEach(SortOption.allCases) { sortOption in<br>                Button {<br>                    selectedSortOption = sortOption<br>                } label: {<br>                    HStack {<br>                        Image(systemName: selectedSortOption == sortOption<br>                              ? &quot;largecircle.fill.circle&quot; : &quot;circle&quot;)<br>Text(sortOption.title)<br>                    }<br>                    .frame(maxWidth: .infinity, alignment: .leading)<br>                    .contentShape(Rectangle())<br>                }<br>                .buttonStyle(.plain)<br>            }<br>            <br>            Button(&quot;Done&quot;) {<br>                onDone(selectedSortOption)<br>                dismiss()<br>                <br>            }.frame(maxWidth: .infinity, alignment: .leading)<br>            .padding([.top], 20)<br>            .buttonStyle(.borderedProminent)<br>            <br>        }.padding()<br>    }<br>}</pre><p>The interesting part of this implementation is the use of a closure instead of passing an @Binding from the parent. The main reason I decided not to use @Binding is that I want users to be able to cancel their sorting selections without affecting the currently applied sort option.</p><p>If we directly bind the selected sort option to the parent’s state, every selection will immediately update that state, even if the user decides to cancel.</p><p>One way to solve this is to introduce a separate draftSortOption in the parent and pass it as a binding to SortView. That approach works perfectly fine, but I prefer a simpler solution.</p><p>In our implementation, SortView manages its own temporary selection using @State. When the user taps the Done button, we pass the selected sort option back to the parent through a closure. If the user closes the sheet without tapping Done, the original sort option remains unchanged.</p><h3>Resources</h3><ul><li><a href="https://azamsharp.teachable.com/p/hummingbird-fundamentals">Hummingbird Fundamentals — Build REST APIs in Swift</a></li><li><a href="https://azamsharp.teachable.com/p/swiftui-vapor-full-stack-ios-development-bootcamp">Full Stack iOS Development Using Swift &amp; Vapor</a></li></ul><h3>Conclusion</h3><p>In this article, we learned how to implement server-side sorting in a SwiftUI application. Instead of fetching all the records and sorting them on the client, we delegated the sorting responsibility to the server. This approach becomes especially useful when working with large datasets.</p><p>We also explored how to use @Observable to manage our hotel data and how to build a sorting interface using SwiftUI sheets. One interesting design decision was using a closure instead of @Binding, allowing users to confirm or cancel their selections without immediately updating the parent state.</p><p>In the next article, we will extend our implementation to support server-side filtering and pagination. This will allow users to narrow down their search results and load hotels in smaller batches instead of fetching everything at once.</p><h3>Continue Learning with AzamSharp School</h3><p>Become an AzamSharp School member and get access to more than 250 hours of practical courses covering SwiftUI, SwiftData, testing, architecture, AI, machine learning, and more.</p><p>Your membership also includes access to AzamSharp books, live workshops, office hours, and new content added regularly.</p><p><a href="https://azamsharp.school/">Join AzamSharp School</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=62bd82feb8ec" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Protecting SwiftUI Views with Authentication]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://levelup.gitconnected.com/protecting-swiftui-views-with-authentication-bc0b92f7c892?source=rss-2300266301b3------2"><img src="https://cdn-images-1.medium.com/max/1672/1*R6yv2uLPkFU2P30gdPk5Vw.png" width="1672"></a></p><p class="medium-feed-snippet">Most applications contain a mix of public and protected content. A user may be able to explore the Home or Contact screen without signing&#x2026;</p><p class="medium-feed-link"><a href="https://levelup.gitconnected.com/protecting-swiftui-views-with-authentication-bc0b92f7c892?source=rss-2300266301b3------2">Continue reading on Level Up Coding »</a></p></div>]]></description>
            <link>https://levelup.gitconnected.com/protecting-swiftui-views-with-authentication-bc0b92f7c892?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/bc0b92f7c892</guid>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[swift-programming]]></category>
            <category><![CDATA[xcode]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <category><![CDATA[ios-development]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Sat, 29 Aug 2026 14:15:52 GMT</pubDate>
            <atom:updated>2026-08-31T14:13:11.597Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Building Testable SwiftData Applications]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/ios-os-x-development/building-testable-swiftdata-applications-48af6ef2030d?source=rss-2300266301b3------2"><img src="https://cdn-images-1.medium.com/max/1600/1*kL8NTkxVn3MNTR21hwmQ7A.png" width="1600"></a></p><p class="medium-feed-snippet">SwiftData makes it incredibly easy to create, save, and fetch models. That convenience can also make it tempting to write unit tests that&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/ios-os-x-development/building-testable-swiftdata-applications-48af6ef2030d?source=rss-2300266301b3------2">Continue reading on iOS App Development »</a></p></div>]]></description>
            <link>https://medium.com/ios-os-x-development/building-testable-swiftdata-applications-48af6ef2030d?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/48af6ef2030d</guid>
            <category><![CDATA[ios-development]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[software-testing]]></category>
            <category><![CDATA[software-architecture]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Thu, 13 Aug 2026 19:37:48 GMT</pubDate>
            <atom:updated>2026-08-13T19:40:25.493Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Syncing SwiftData with a Custom Backend Using HistoryObserver]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://azamsharp.medium.com/syncing-swiftdata-with-a-custom-backend-using-historyobserver-87f43feca602?source=rss-2300266301b3------2"><img src="https://cdn-images-1.medium.com/max/1672/1*D4c84d_JqrxXgUnBadFAyw.png" width="1672"></a></p><p class="medium-feed-snippet">Many applications need to store data locally while also keeping a copy on a backend server. This is common in business applications where&#x2026;</p><p class="medium-feed-link"><a href="https://azamsharp.medium.com/syncing-swiftdata-with-a-custom-backend-using-historyobserver-87f43feca602?source=rss-2300266301b3------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://azamsharp.medium.com/syncing-swiftdata-with-a-custom-backend-using-historyobserver-87f43feca602?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/87f43feca602</guid>
            <category><![CDATA[ios-app-development]]></category>
            <category><![CDATA[swift-programming]]></category>
            <category><![CDATA[swiftdata]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[ios-development]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Fri, 17 Jul 2026 15:32:46 GMT</pubDate>
            <atom:updated>2026-07-17T15:32:46.348Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Where Should Loading State Live in SwiftUI?]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://azamsharp.medium.com/where-should-loading-state-live-in-swiftui-81751f78ecf9?source=rss-2300266301b3------2"><img src="https://cdn-images-1.medium.com/max/1672/1*UG4BxFe8fiSZgAYmG8auWw.png" width="1672"></a></p><p class="medium-feed-snippet">Handling loading states is something every SwiftUI application has to deal with.</p><p class="medium-feed-link"><a href="https://azamsharp.medium.com/where-should-loading-state-live-in-swiftui-81751f78ecf9?source=rss-2300266301b3------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://azamsharp.medium.com/where-should-loading-state-live-in-swiftui-81751f78ecf9?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/81751f78ecf9</guid>
            <category><![CDATA[programming-languages]]></category>
            <category><![CDATA[swift-programming]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <category><![CDATA[ios-development]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Wed, 01 Jul 2026 00:38:50 GMT</pubDate>
            <atom:updated>2026-07-01T00:38:50.232Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[What’s New in SwiftData for iOS 27]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://azamsharp.medium.com/whats-new-in-swiftdata-for-ios-27-8afbd045f968?source=rss-2300266301b3------2"><img src="https://cdn-images-1.medium.com/max/1672/1*IbJfmkY7vX-lj3IFV4m1Wg.png" width="1672"></a></p><p class="medium-feed-snippet">WWDC is always an exciting time for Swift developers. Every year Apple introduces new APIs, refines existing frameworks, and occasionally&#x2026;</p><p class="medium-feed-link"><a href="https://azamsharp.medium.com/whats-new-in-swiftdata-for-ios-27-8afbd045f968?source=rss-2300266301b3------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://azamsharp.medium.com/whats-new-in-swiftdata-for-ios-27-8afbd045f968?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/8afbd045f968</guid>
            <category><![CDATA[swift-programming]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[ios-development]]></category>
            <category><![CDATA[swiftdata]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Fri, 26 Jun 2026 05:40:45 GMT</pubDate>
            <atom:updated>2026-06-26T05:40:45.041Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Announcing My New Book: SwiftData Architecture]]></title>
            <link>https://azamsharp.medium.com/announcing-my-new-book-swiftdata-architecture-f8ad65faaea6?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/f8ad65faaea6</guid>
            <category><![CDATA[swiftdata]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[core-data]]></category>
            <category><![CDATA[ios-development]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Tue, 16 Jun 2026 15:22:10 GMT</pubDate>
            <atom:updated>2026-06-16T15:22:10.066Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9wN6YVMeLqIni26RZo9XwA.png" /></figure><p>After many months of writing, researching, testing, and revising, I am excited to announce the release of my new book:</p><p><a href="https://azamsharp.school/swiftdata-architecture.html"><strong>SwiftData Architecture — Patterns and Practices for Building Scalable Applications</strong></a></p><p>SwiftData has quickly become the preferred persistence framework for many Apple developers. It provides a modern API, deep SwiftUI integration, and significantly reduces the amount of boilerplate code required to build data-driven applications.</p><p>The demos look great.</p><p>The sample applications work perfectly.</p><p>Then real-world development begins.</p><h3>Why I Wrote This Book</h3><p>Most SwiftData tutorials focus on getting started.</p><p>Create a model.</p><p>Create a query.</p><p>Save some data.</p><p>Everything works.</p><p>But once your application starts growing, new challenges emerge:</p><ul><li>How should you structure your application?</li><li>How do you test SwiftData applications?</li><li>How do dynamic queries work?</li><li>When should you use external storage?</li><li>How do you debug SwiftData problems?</li><li>What happens when CloudKit synchronization enters the picture?</li><li>How do you handle large datasets efficiently</li><li>Can you build your own custom data store?</li></ul><p>These are the questions I encountered while building real applications and experimenting extensively with SwiftData.</p><p>This book is my attempt to answer those questions.</p><h3>What’s Inside</h3><p>The book covers a wide range of SwiftData topics, including:</p><h3>SwiftData Architecture</h3><p>Learn practical approaches for organizing SwiftData applications without introducing unnecessary complexity.</p><h3>Debugging SwiftData</h3><p>Discover techniques for inspecting your data store, understanding generated schemas, and troubleshooting common issues.</p><h3>Dynamic Queries</h3><p>Learn how to build applications that support searching, filtering, and sorting while working within SwiftData’s query system.</p><h3>CloudKit Synchronization</h3><p>Explore common CloudKit challenges and practical solutions for building synchronized applications.</p><h3>Performance Optimization</h3><p>Learn techniques for handling large datasets using fetch limits, pagination strategies, external storage, and background operations.</p><h3>Custom Data Stores</h3><p>One of my favorite chapters covers building a custom SwiftData data store from scratch. This helps developers understand how SwiftData works under the hood while opening possibilities for alternative storage implementations.</p><h3>New SwiftData Features</h3><p>The book also covers many of the latest SwiftData capabilities, including:</p><ul><li>Sectioned Queries</li><li>ResultsObserver</li><li>HistoryObserver</li><li>Codable Attributes</li><li>Compound Predicates</li><li>Improved Preview Support</li></ul><h3>Who Is This Book For?</h3><p>This book is designed for developers who have already used SwiftData and want to move beyond the basics.</p><p>If you have built a few SwiftData applications and started asking questions like:</p><blockquote><em>“How do I structure this for production?”</em></blockquote><p>or</p><blockquote><em>“What happens when this app grows?”</em></blockquote><p>then this book was written for you.</p><h3>A Practical Book</h3><p>My goal was not to create a reference manual.</p><p>Apple’s documentation already does an excellent job of explaining APIs.</p><p>Instead, I wanted to focus on practical techniques, lessons learned, tradeoffs, and real-world scenarios that developers encounter while building applications.</p><p>Many examples in the book are inspired by actual problems I have encountered while teaching, consulting, and building applications.</p><h3>Thank You</h3><p>Writing a technical book is a much larger undertaking than most people realize.</p><p>It involves researching APIs, building sample applications, testing code across multiple releases, revising chapters, and constantly updating content as the framework evolves.</p><p>I am grateful to everyone who provided feedback, reviewed early drafts, reported issues, and encouraged me throughout the process.</p><p>I hope this book helps developers build better SwiftData applications and avoid some of the mistakes I made along the way.</p><h3>Learn More</h3><p>You can learn more about the book here:</p><p><a href="https://azamsharp.school/swiftdata-architecture.html">https://azamsharp.school/swiftdata-architecture.html</a></p><p>I am excited to see what you build with SwiftData.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f8ad65faaea6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Tracking App Store Purchases with Server Notifications]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://azamsharp.medium.com/storekit-2-handles-purchases-this-handles-everything-else-4a659094b7fb?source=rss-2300266301b3------2"><img src="https://cdn-images-1.medium.com/max/1672/1*4JqJ38okuRfdDE0sYFHEXQ.png" width="1672"></a></p><p class="medium-feed-snippet">Last year I released several apps to the App Store and all of them used In-App Purchases.</p><p class="medium-feed-link"><a href="https://azamsharp.medium.com/storekit-2-handles-purchases-this-handles-everything-else-4a659094b7fb?source=rss-2300266301b3------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://azamsharp.medium.com/storekit-2-handles-purchases-this-handles-everything-else-4a659094b7fb?source=rss-2300266301b3------2</link>
            <guid isPermaLink="false">https://medium.com/p/4a659094b7fb</guid>
            <category><![CDATA[ios-app-development]]></category>
            <category><![CDATA[swift-programming]]></category>
            <category><![CDATA[ios-development]]></category>
            <category><![CDATA[swiftui]]></category>
            <category><![CDATA[in-app-purchase]]></category>
            <dc:creator><![CDATA[Mohammad Azam]]></dc:creator>
            <pubDate>Sat, 16 May 2026 19:25:12 GMT</pubDate>
            <atom:updated>2026-05-16T22:56:58.659Z</atom:updated>
        </item>
    </channel>
</rss>