<?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 Harsimran Singh on Medium]]></title>
        <description><![CDATA[Stories by Harsimran Singh on Medium]]></description>
        <link>https://medium.com/@harsimrans329?source=rss-1280a7c58293------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*zB7BLL0SdX2brcpT8qgGyQ@2x.jpeg</url>
            <title>Stories by Harsimran Singh on Medium</title>
            <link>https://medium.com/@harsimrans329?source=rss-1280a7c58293------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 07:56:44 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@harsimrans329/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[Setting State in Mobile Reactive Programming Frameworks]]></title>
            <link>https://medium.com/@harsimrans329/setting-state-in-mobile-reactive-programming-frameworks-8bb8e0ebf308?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/8bb8e0ebf308</guid>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[state-management]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Wed, 01 Mar 2023 17:20:15 GMT</pubDate>
            <atom:updated>2023-03-01T17:20:15.086Z</atom:updated>
            <content:encoded><![CDATA[<p>In reactive programming, managing state is essential for creating dynamic and responsive user interfaces that react to changes and updates in real-time. Setting state is the process of updating the current state in response to user input or other events, enabling developers to build complex, interactive applications with minimal code. Setting state automatically triggers updates to the user interface, reducing the need for manual updates and minimizing the potential for bugs and errors. Overall, setting state is a critical aspect of building reactive applications that deliver a seamless user experience.</p><p>Here’s a comparison of how to set state in some popular mobile development frameworks:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*EkLjNX8alPKY0dDmzp5V0Q.png" /></figure><p>In <strong>Android Compose</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XMAAtghMccgHgOtf3TyS1A.png" /></figure><p>In Android, state can be managed using the mutableStateOf() function, which returns a MutableState object that can be read and updated using the value property. Alternatively, the state property can be used, which is a convenience wrapper around mutableStateOf().</p><p>In Compose, state can be managed using the remember function, which creates a variable that survives recomposition, and the mutableStateOf() function, which creates a mutable state object that can be updated. The state can be accessed using the value property or using a property delegate such as var state by remember { mutableStateOf() }.</p><p>In <strong>Swift UI</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C5Hzx_Qcnq_YLsiXbNHtOA.png" /></figure><p>In SwiftUI, state can be managed using the @State property wrapper, which creates a state variable that can be updated using the self.propertyName = syntax. The state can be accessed using the value property or by using a property wrapper such as @State private var state.</p><p>In <strong>RN</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VlTL6ri2DNVBqNyCpy2_lw.png" /></figure><p>In React Native, state can be managed using the useState hook, which returns an array containing the current state and a function to update the state. Alternatively, the this.setState({}) method can be used to update the state of a class-based component.</p><p>In <strong>Flutter</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xdCxzdJ5fu_Rs3EFPXav9g.png" /></figure><p>In Flutter, state can be managed using the setState(() {}) method, which takes a function that updates the state of the widget. Alternatively, state can be managed using stateful widgets, which have a mutable state that can be updated using the setState(() {}) method.</p><p><strong>Summary</strong></p><p>Setting state is essential in reactive programming for managing the current state of an application or component. It enables dynamic and responsive user interfaces that automatically update in real-time. By setting state, developers can build complex and interactive applications with minimal code and reduce the potential for errors.</p><p><strong>Github</strong> — <a href="https://github.com/harry329/ReactiveProgramming/tree/main/State">https://github.com/harry329/ReactiveProgramming/tree/main/State</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8bb8e0ebf308" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Floating Action Button (FAB) in Mobile Reactive Programming]]></title>
            <link>https://medium.com/@harsimrans329/floating-action-button-fab-in-mobile-reactive-programming-bfb217876f3c?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/bfb217876f3c</guid>
            <category><![CDATA[user-experience]]></category>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[mobile-app-development]]></category>
            <category><![CDATA[reactive-programming]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Thu, 23 Feb 2023 17:26:03 GMT</pubDate>
            <atom:updated>2023-02-23T17:26:03.746Z</atom:updated>
            <content:encoded><![CDATA[<p>A floating action button (FAB) is a circular button that hovers above the user interface of a mobile app, typically placed at the bottom-right corner of the screen. It is often used to provide the user with quick access to the most important or commonly used action(s) of the app.</p><p>Here are some of the importance and benefits of using a floating action button in mobile apps:</p><ol><li><strong>Prominence and visibility</strong>: FABs are a prominent and visible UI element that catches the user’s attention, making it an effective way to highlight important or frequently used actions in your app.</li><li><strong>Easy and quick access:</strong> FABs are always within reach of the user’s thumb, making it easy to access and use the primary or most common action(s) of the app.</li><li><strong>Consistency:</strong> FABs are commonly used in many mobile apps, which creates consistency across apps and provides users with a familiar UI element that they are accustomed to.</li><li><strong>Aesthetically pleasing design:</strong> FABs are often designed to be visually appealing and complement the overall UI design of the app.</li><li><strong>Space-saving:</strong> FABs take up less space on the screen than other UI elements, such as a toolbar or bottom navigation bar, which makes it ideal for smaller screens and devices.</li></ol><p>In <strong>Android Compose</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*U7S2TVM8hgoZS40W3zWa0g.png" /></figure><p>In <strong>SwiftUI</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FLPtSWiA2NVpQUK-qa1-OA.png" /></figure><p>In <strong>RN</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MUi0KrSWHgAiJ5wEOYVP3Q.png" /></figure><p>In <strong>Flutter</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Rvmyy546SLLLn_CSgsi9uw.png" /></figure><p>When designing screens in mobile apps, it is important to carefully consider the placement and usage of FABs. FABs should be used sparingly and only for the most important or commonly used actions in the app. Overuse of FABs can clutter the UI and make it confusing for users to determine the primary action(s) of the app. Additionally, FABs should be placed in a position that is easily accessible to the user and does not interfere with other UI elements or content on the screen</p><p>Git Repo — <a href="https://github.com/harry329/ReactiveProgramming/tree/main/FAB">https://github.com/harry329/ReactiveProgramming/tree/main/FAB</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bfb217876f3c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[TextView In Mobile Reactive Program]]></title>
            <link>https://medium.com/@harsimrans329/textview-in-mobile-reactive-program-6717a6ca7e53?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/6717a6ca7e53</guid>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[mobile-app-development]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[mobile-apps]]></category>
            <category><![CDATA[reactive-programming]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Tue, 21 Feb 2023 05:14:49 GMT</pubDate>
            <atom:updated>2023-02-21T05:14:49.100Z</atom:updated>
            <content:encoded><![CDATA[<p>In this article, I will cover how TextView is written and shown in different UI Frameworks for android &amp; iOS.</p><p>In <strong>Android Compose</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kycnlVue3d0C_Qa4RBEoiA.png" /></figure><p>In <strong>Swift UI</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*S8D5HIp4cmjp0JzuQP_mMA.png" /></figure><p>In <strong>ReactNative</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kiJyxq8n0Y2hn9rQNyd6PA.png" /></figure><p>In <strong>Flutter</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sJhpIjmOd01p43ol-kYKUw.png" /></figure><p>In this series, I will cover how things are done on different UI Frameworks for Android and iOS apps.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6717a6ca7e53" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Interaction between Smart Contracts]]></title>
            <link>https://medium.com/@harsimrans329/interaction-between-smart-contracts-736d91466a4a?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/736d91466a4a</guid>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[solidity]]></category>
            <category><![CDATA[ethereum-blockchain]]></category>
            <category><![CDATA[crypto]]></category>
            <category><![CDATA[blockchain]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Thu, 17 Feb 2022 18:25:57 GMT</pubDate>
            <atom:updated>2022-02-17T18:25:57.679Z</atom:updated>
            <content:encoded><![CDATA[<p>In our <a href="https://medium.com/@harsimrans329/structure-building-blocks-of-smart-contract-499ce9003557">first</a> &amp; <a href="https://medium.com/@harsimrans329/structure-building-blocks-of-smart-contract-part-2-9b04751144f4">second</a> part of this series we learned how to write &amp; deploy our single contract on blockchain and how we can interact with deployed smart contracts. But as we start adding more complex functionalities in our contracts our contracts will start getting bigger and would be cause of potential bugs or security threats. The risk of potential security threats or bugs substantially reduces if we can divide one big contract into smaller pieces depending upon certain parameters i.e. data &amp; business contracts or modularize contracts depending upon functionality(will discuss these approach in next lessons). There might be case where we might have to use already deployed contract functionality. In all these cases, we need to call functions of other contract from our contract. In this lesson we are going to explore how we can call other contract’s functionality from our contract.</p><p>In this example, we will create two contracts first one SmartBook &amp; BookKeeping . SmartBook is business application contract which adds people and businesses &amp; BookKeeping is data contract where actual data of people &amp; business is save or fetched by SmartBook .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BeVFD3VGMaaXTasP3Z2Ebg.png" /><figcaption>Contracts</figcaption></figure><p>Once we have skeletons ready, let’s start adding functionality to BookKeeping contract. In the code snippet, you can see two dynamic arrays declared which will keep track of businesses and people as SmartBook will add those. Let’s define functions to add people &amp; business and fetch number of businesses &amp; people added so far.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rufulOfoWc-bOdJykhMMGw.png" /><figcaption>Functions added to BookKeeping</figcaption></figure><p>Now we have defined BookKeeping contract functionality, let’s add code to SmartBook . We will define functions which will be called by user of this smart contract (front end/service) to people or businesses. But before that we need to have reference to BookKeeping contract so that we call the functions defined in that contract. Let’s define BookKeeping variable and pass the address to it’s initializer in the constructor of SmartBook as below</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Z7z9SJaBikuFdWvCvjZE_w.png" /><figcaption>SmartBook with ref to BookKeeping</figcaption></figure><p>Now we have reference to BookKeeping contract in SmartBook , let’s start adding functionality where user can add business or people. In this function we will call the BookKeeping contract’s function to add and fetch business &amp; people. We will add function addEntity with name &amp; isBusiness as params , in this function we will use bookKeeping ref to call addBusiness or addPeople functions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lXGT5qquIL3Qi-rfGEwIsw.png" /></figure><p>Let’s compile this code, once compilation is successful let’s deploy the compiled code. Here we need to keep one imp thing in mind, we need to deploy BookKeeping contract first and then SmartBook. While deploying SmartBook you will see , it asks for BookKeeping contract’s address.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fpcDd_xG0ewk8fUFpsnFbA.png" /><figcaption>SmartBook Contract deployed</figcaption></figure><p>Once the code is compiled &amp; deployed, play around and make some calls to the contracts. In next few articles, we will cover how we can make one contract publicly available while restrict the access to other contract.</p><p>Keep Learning, cheers.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=736d91466a4a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Structure & Building Blocks of Smart Contract- Part 2]]></title>
            <link>https://medium.com/@harsimrans329/structure-building-blocks-of-smart-contract-part-2-9b04751144f4?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/9b04751144f4</guid>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[smartcontractdevelopment]]></category>
            <category><![CDATA[solidity]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[smart-contracts]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Tue, 15 Feb 2022 03:36:15 GMT</pubDate>
            <atom:updated>2022-02-15T03:36:15.391Z</atom:updated>
            <content:encoded><![CDATA[<p>In our last <a href="https://medium.com/@harsimrans329/structure-building-blocks-of-smart-contract-499ce9003557">article</a>, we have seen how to get start writing smart contracts on <a href="https://remix.ethereum.org/">remix</a>. So far we have covered contract creation, state variables, functions &amp; events.In this article we are gonna discuss about modifiers, structs ,enums &amp; errors.</p><p><strong><em>Enums</em></strong>- Let’s start with enums. Enums are user-defined type with finite set of values. Enums are explicitly converted to and from integer types. Enum need to have at-least one value and maximum of 256 values.Enums are created using enum keyword followed by name of enum and values enum can have. Let’s create a SkillLevel enum in our contract which will have three values ROOKIE,EXPERIENCED &amp; EXPERT.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HrWEeR51xccwxmY_99h_Gw.png" /><figcaption>Enum</figcaption></figure><p><strong><em>Structs</em></strong>- Structs are user-defined types which can group other types. Struct can have primitive types and other structs as well. Structs are created using structkeyword followed by name of struct and types &amp; name of those types. Let’s define Friend struct in our contract which will have string, int &amp; SkillLevel(enum) types.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XddYKNqkc3SyM76PpHk0sQ.png" /><figcaption>Struct</figcaption></figure><p><strong><em>Error</em></strong>- Errors are way of telling user of contract what went wrong in case of failure. Preferred way of using error is with revert statement(will show later in this tutorial). Errors are created using error keyword followed by name of error and values error can have. Let’s define SkillLevelUnknown error in our contract.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0-CuzwyvuejTJ1EGz-43GA.png" /><figcaption>Error</figcaption></figure><p><strong><em>Modifier — </em></strong>Modifiers are used to check pre-conditions before running functions body. Execution of program should halt quickly as it costs gas to run piece of code on ethereum blockchain. Modifiers help us to state these in declarative way before running functions code.Modifiers are created using modifier keyword and followed by name of modifier and values modifier can have. Let’s define checkFriendAge modifier in our contract. _; is special syntax which tells to follow the function flow if condition is met.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*J7efIDtsuZ3CUYepI0-fbQ.png" /><figcaption>Modifier</figcaption></figure><p>Let’s tie up all the pieces together and create two new functions addFriend &amp; fetchFriendName like below. Compile the <a href="https://gist.github.com/harry329/e327e8137b219793c3119bda6a39edd9">code</a> and play around with age &amp; skillLevel value to see how errors and modifiers worked.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nsCl6YYFk7JjeYBirtPRpw.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9b04751144f4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Structure & Building Blocks of Smart Contract]]></title>
            <link>https://medium.com/@harsimrans329/structure-building-blocks-of-smart-contract-499ce9003557?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/499ce9003557</guid>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[smart-contracts]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[etherum-blockchain]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Wed, 09 Feb 2022 21:11:00 GMT</pubDate>
            <atom:updated>2022-02-15T03:39:44.651Z</atom:updated>
            <content:encoded><![CDATA[<p>By this time, almost all of us have heard about Smart Contracts powered by Blockchain technology in some capacity. If you are one of those inquisitive minds who like to know how things work you would be wondering what’s so unique or smart about these contracts. In this article, I would be going over Structure &amp; building blocks of these smart contracts. I would using Ethereum blockchain and solidity language as this the most widely used tech stack for smart contracts. If you want to follow along you can open web ide <a href="https://remix.ethereum.org/">Remix</a>.</p><p>Before start writing our first smart contract, let’s go over to remix and understand what we need to do there. When you first open up the remix ,it will show you screen like below</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xs1sv6ASXrTF0JliW2utwg.png" /><figcaption>License Identifier</figcaption></figure><p>In default workspace, go ahead and create file FirstContract.sol(extension of file is .sol as we are writing the code in solidity). Go to the file created, and write the first line `<strong><em>// SPDX-License-Identifier: GPL-3.0</em></strong>` . This line isn’t mandatory but recommended as it tells under which license this Smart Contract adheres to. Once this setup is done, let’s start writing our First Smart Contract</p><p>The first thing you need to do in any Smart Contract is to tell which version of solidity your contract will be using to write up the code , which will be done using pragma solidity &gt;=0.7.0 &lt;0.9.0; . In this line , we are tell our code can be compiled for any version ranging from 0.7.0 to 0.9.0.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dtMHWaEoSeeKpMilMncZMA.png" /><figcaption>Solidity Version</figcaption></figure><p><strong><em>Contract Creation</em></strong> — Next Step will be declaring contract FirstContract{} . Technically speaking we are done writing our FirstSmart contract. You can go ahead compile &amp; deploy this contract. As you can see there’s nothing so smart about Smart Contracts , they are just simple files similar to classes (reference to other programming langs). The important thing is what we do inside these contract and how we implement functionalities using other building blocks, which we go over shortly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9tI-38JRH32sbx8eR669VQ.png" /><figcaption>Contract Creation</figcaption></figure><p><strong><em>State Variable</em></strong> — Once we have our contract, go ahead and declare string variable myName. State variables values are stored permanently in contract storage. Go ahead and compile the contract to check if everything’s working fine.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZAo5R825d4EkBN7bhQJmlw.png" /><figcaption>State Variable</figcaption></figure><p><strong><em>Functions</em></strong> — Next step will be declaring functions, where we will be setting state variable and fetching it’s value as well. Functions are declared using function keyword, followed by the name , arguments , visibility modifiers and return type.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*I-D6LHCkk1ji4W2QshA30g.png" /><figcaption>Functions</figcaption></figure><p><strong><em>Events</em></strong> — Before setting up Events, go ahead and compile your contract to see if everything’s working fine. Events are used to log information on blockchain. Events are declared using event EventName(...params) and used emit EventName(..arguments) .</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6YEzIc3HrhQhV4CjuvGMhQ.png" /><figcaption>Events</figcaption></figure><p>Once we have this code ready, let’s go and deploy this contract. Once we have deployed our contract, hooray we have created and deployed our first Smart Contract though not on Mainnetyet. We can go and interact with our contract.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sDoCQ6ZOfdLwAk-fav8pWw.png" /><figcaption>First Contract Deployed 👏</figcaption></figure><p>This is the first part of Structure &amp; Building blocks of Smart Contract in which we covered contract creation, state variables, functions &amp; events. In <a href="https://medium.com/@harsimrans329/structure-building-blocks-of-smart-contract-part-2-9b04751144f4">next part</a> we will cover modifiers, structs ,enums &amp; errors.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=499ce9003557" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Declarative approach in Mobile development]]></title>
            <link>https://medium.com/@harsimrans329/declarative-approach-in-mobile-development-d9b3a927f331?source=rss-1280a7c58293------2</link>
            <guid isPermaLink="false">https://medium.com/p/d9b3a927f331</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[moblie]]></category>
            <category><![CDATA[development]]></category>
            <category><![CDATA[android-app-development]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <dc:creator><![CDATA[Harsimran Singh]]></dc:creator>
            <pubDate>Wed, 09 Feb 2022 00:26:09 GMT</pubDate>
            <atom:updated>2022-02-09T00:26:09.733Z</atom:updated>
            <content:encoded><![CDATA[<p>As we have more than one option to develop mobile native apps which include Native Android, Native iOS, Flutter and RN, I will be writing this Mobile Dev Series articles where I will go and write about development &amp; designing of similar concepts in these different Ecosystems.</p><p>For the first part in this series I took pretty simple but important concept of Declarative UI paradigm in mobile development. If you been developing mobile apps from long time , you would remember mobile apps were written imperatively (which is still the case at big corporations with legacy codebase).For newer devs, in imperative design app flows go something like this → User Takes Action → Action updates data model → Depending on Val we change UI in response imperatively like text.setText(&quot;I am updated&quot;).</p><p>In declarative approach, there’s little update to this flow State Defined → Depending upon different vals of State, UI is declared for all those different state vals in code→ Actions are defined which user can take in those states, which in turn will update the state . Basically UI is declared as f(State). All the states UI can be in is declared in code preemptively.</p><p>Flutter, RN, Android Compose and Swift UI all follow this declarative approach for developing new components. One big advantage of declarative approach over imperative which I found very compelling is less boilerplate code. With declarative approach, we don’t have to keep xml layout(android) &amp; storyboard(iOS) files, which in my experience becomes very cumbersome to update and maintain.</p><p>In next article I will walk through the basic app using declarative approach in RN, Flutter, Compose Android &amp; SwiftUI.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d9b3a927f331" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>