<?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 Bhavik Shah on Medium]]></title>
        <description><![CDATA[Stories by Bhavik Shah on Medium]]></description>
        <link>https://medium.com/@bnshah.dev?source=rss-467dfe480b0d------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*tdURBDL2-8MTTmFPGog3Rw.jpeg</url>
            <title>Stories by Bhavik Shah on Medium</title>
            <link>https://medium.com/@bnshah.dev?source=rss-467dfe480b0d------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 20 Nov 2026 02:49:26 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@bnshah.dev/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[High level strategies for working effectively with Claude and similar AI tools — Evaluate and…]]></title>
            <link>https://medium.com/@bnshah.dev/high-level-strategies-for-working-effectively-with-claude-and-similar-ai-tools-evaluate-and-8191713fabb2?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/8191713fabb2</guid>
            <category><![CDATA[claude]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Tue, 19 May 2026 13:58:04 GMT</pubDate>
            <atom:updated>2026-05-19T13:58:04.866Z</atom:updated>
            <content:encoded><![CDATA[<p>High level strategies for working effectively with Claude and similar AI tools — Evaluate and Elevate!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RZgPx7Wa_m0nOEF3wUMUJA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8191713fabb2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Simplify Git Repository Management for Micro-Frontend Apps with Gita]]></title>
            <link>https://medium.com/@bnshah.dev/simplify-git-repository-management-for-micro-frontend-apps-with-gita-0df892a932b2?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/0df892a932b2</guid>
            <category><![CDATA[micro-front-end]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[git]]></category>
            <category><![CDATA[reactjs]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Sun, 29 Dec 2024 01:45:39 GMT</pubDate>
            <atom:updated>2024-12-29T01:45:39.010Z</atom:updated>
            <content:encoded><![CDATA[<p>Managing multiple Git repositories becomes especially crucial when working with micro-frontend applications.</p><p>In such architectures, a single host app integrates multiple micro-apps, each maintained in its own repository.</p><p>The Python library <strong>Gita</strong> offers a powerful solution to streamline this process by enabling simultaneous management of these repositories with just a few commands, which personally I found very handy.</p><h3>Why Use Gita for Micro-Frontend Projects?</h3><p>Micro-frontend architectures inherently involve managing multiple repositories for the host app and its micro-apps. Manually switching between directories and pulling updates can be cumbersome. Gita simplifies this by:</p><ul><li>Allowing bulk operations like pulling updates across all repositories.</li><li>Displaying the status of multiple repositories in a single view.</li><li>Customizing repositories into groups for focused management, such as separating host and micro-apps.</li></ul><h3>Folder Hierarchy for Micro-Frontend Apps</h3><p>Here is an example folder structure for a micro-frontend application setup:</p><pre>my-micro-app-project/<br>├── host-app/                # The main application hosting the micro-apps<br>│   ├── public/<br>│   ├── src/<br>│   ├── package.json<br>│   └── ...<br>├── micro-app1/              # First micro-frontend application<br>│   ├── public/<br>│   ├── src/<br>│   ├── package.json<br>│   └── ...<br>├── micro-app2/              # Second micro-frontend application<br>│   ├── public/<br>│   ├── src/<br>│   ├── package.json<br>│   └── ...<br>└── micro-appN/              # Additional micro-apps<br>    ├── public/<br>    ├── src/<br>    ├── package.json<br>    └── ...</pre><p>This structure separates the host app and each micro-app into their respective directories, making it easier to manage repositories and dependencies.</p><h3>Getting Started with Gita</h3><p>Installing Gita is straightforward:</p><pre>pip install gita</pre><p>Once installed, you can start managing your micro-frontend repositories:</p><p><strong>Add repositories:</strong></p><pre>gita add /path/to/host-app /path/to/micro-app1 /path/to/micro-app2</pre><p><strong>Pull updates for all repositories:</strong></p><pre>gita pull</pre><h3>Grouping Repositories for Micro-Frontend Apps</h3><p>Gita’s grouping feature is especially useful for micro-frontend projects. We can group repositories for better control:</p><pre>gita add /path/to/host-app /path/to/micro-app1 /path/to/micro-app2 -n my-micro-app-project-group</pre><p>Now, we can perform operations on specific groups:</p><pre>gita pull my-micro-app-project-group</pre><h3>Conclusion</h3><p>For developers working on micro-frontend architectures, Gita is an indispensable tool.</p><p>Its ability to manage multiple repositories, perform bulk operations, and organize repositories into groups makes it ideal for handling the complexities of micro-frontend projects.</p><p>Try it out today and simplify your workflow!</p><p>For more details, visit Gita’s <a href="https://github.com/nosarthur/gita">official documentation</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0df892a932b2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Choosing the Right UI Component Strategy: Essential for Long-Term Branding!]]></title>
            <link>https://medium.com/@bnshah.dev/choosing-the-right-ui-component-strategy-essential-for-long-term-branding-1d499450235d?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/1d499450235d</guid>
            <category><![CDATA[ui-design]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[ui]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Sun, 01 Sep 2024 15:21:50 GMT</pubDate>
            <atom:updated>2024-09-01T15:21:50.738Z</atom:updated>
            <content:encoded><![CDATA[<p>Selecting the right UI component library is crucial for the success and consistency of the brand over the long haul.</p><p>Start strong with your next React app by leveraging popular UI component libraries (possibly default or customized components).</p><p>Here’s a quick rundown of some top contenders:</p><p>👉 <strong>Material-UI (MUI) (90.7k+ ⭐) </strong><br>Usage: MUI is widely adopted in React projects, offering a comprehensive set of components that adhere to Google’s Material Design guidelines.</p><p>Use Case: Ideal for developers aiming to implement clean, consistent UI designs swiftly, with an emphasis on accessibility and responsiveness.</p><p>👉 <strong>Ant Design (89.3k+ ⭐) </strong><br>Usage: Ant Design is popular in enterprise-level applications, providing a suite of high-quality components tailored for React, focusing on elegance and usability.</p><p>Use Case: Perfect for complex business applications where a polished, professional appearance is essential.</p><p>👉<strong> Bootstrap (166.5k+ ⭐) </strong><br>Usage: Bootstrap is the go-to library for responsive, mobile-first web development. Its extensive set of components and grid system make it a favorite among both new and seasoned developers.</p><p>Use Case: Best for projects that prioritize quick setup and robust, responsive design.</p><p>👉 <strong>Tailwind CSS (72.8k+ ⭐) </strong><br>Usage: Tailwind is a utility-first CSS framework that empowers developers to create custom designs without writing custom CSS.</p><p>Use Case: Ideal for developers seeking complete control over design without being constrained by pre-built components.</p><p>👉 <strong>Chakra UI (35.7k+ ⭐) </strong><br>Usage: Chakra UI is a simple, modular, and accessible component library for React, offering customizable, responsive components out of the box.</p><p>Use Case: Great for projects requiring flexibility and customization, with a strong emphasis on accessibility.</p><p><strong>Quick Demos:</strong></p><p>👉 Material-UI (MUI): <a href="https://minimals.cc/">https://minimals.cc/</a></p><p>👉 Ant Design: <a href="https://preview.pro.ant.design/dashboard/analysis">https://preview.pro.ant.design/dashboard/analysis</a></p><p>👉 Bootstrap:<br><a href="https://prium.github.io/phoenix/v1.19.0/index.html">https://prium.github.io/phoenix/v1.19.0/index.html</a><br><a href="https://finder.createx.studio/real-estate-home-v1.html">https://finder.createx.studio/real-estate-home-v1.html</a></p><p>👉 Tailwind CSS: <a href="https://githubnext.com/">https://githubnext.com/</a></p><p>👉 Chakra UI: <a href="https://pro.chakra-ui.com/">https://pro.chakra-ui.com/</a></p><p><a href="https://www.linkedin.com/feed/hashtag/?keywords=react&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#react</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=ui&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#ui</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=mui&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#mui</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=chakraui&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#chakraui</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=uicomponents&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#uicomponents</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=bootstrap&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#bootstrap</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=css&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#css</a> <a href="https://www.linkedin.com/feed/hashtag/?keywords=javascript&amp;highlightedUpdateUrns=urn%3Ali%3Aactivity%3A7236029026669137923">hashtag#javascript</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1d499450235d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[“You are perceived only as good as you can communicate” — is especially very much true for…]]></title>
            <link>https://medium.com/@bnshah.dev/you-are-perceived-only-as-good-as-you-can-communicate-is-especially-very-much-true-for-f0cb50e3e38f?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/f0cb50e3e38f</guid>
            <category><![CDATA[low-level-design]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[design-patterns]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Thu, 29 Aug 2024 23:17:50 GMT</pubDate>
            <atom:updated>2024-08-29T23:21:57.964Z</atom:updated>
            <content:encoded><![CDATA[<h3>React Components — Low level design patterns</h3><p>“You are perceived only as good as you can communicate” — is especially very much true for Technical Communication.</p><p>Below is consolidated list of foundational patterns with brief snippet, which to be discussed around during React component low level design, technically!</p><p><strong>1. Functional Components</strong><br>The simplest form of a React component, defined as a function that takes props and returns JSX. They are stateless and purely presentational.</p><blockquote>Example:<br>function Greeting({ name }) {<br> return &lt;h1&gt;Hello, {name}!&lt;/h1&gt;;<br>}</blockquote><p><strong>2. Class Components</strong><br>A more feature-rich component pattern, defined using ES6 classes. They can manage their own state and lifecycle methods.</p><blockquote>Example:<br>class Greeting extends React.Component {<br> render() {<br> return &lt;h1&gt;Hello, {this.props.name}!&lt;/h1&gt;;<br> }<br>}</blockquote><p><strong>3. Higher-Order Components (HOC)</strong><br>A pattern where a function takes a component and returns a new component, typically to add additional functionality (like logging, data fetching, etc.).</p><blockquote>Example:<br>function withLogging(WrappedComponent) {<br> return function(props) {<br> console.log(‘Rendering’, WrappedComponent.name);<br> return &lt;WrappedComponent {…props} /&gt;;<br> };<br>}</blockquote><blockquote>const EnhancedComponent = withLogging(Greeting);</blockquote><p>4. <strong>Render Props</strong><br>A technique for sharing logic between components using a prop whose value is a function.</p><blockquote>Example:<br>class MouseTracker extends React.Component {<br> state = { x: 0, y: 0 };</blockquote><blockquote>handleMouseMove = (event) =&gt; {<br> this.setState({<br> x: event.clientX,<br> y: event.clientY,<br> });<br> };</blockquote><blockquote>render() {<br> return (<br> &lt;div onMouseMove={this.handleMouseMove}&gt;<br> {this.props.render(this.state)}<br> &lt;/div&gt;<br> );<br> }<br>}</blockquote><blockquote>function App() {<br> return (<br> &lt;MouseTracker render={({ x, y }) =&gt; (<br> &lt;h1&gt;The mouse position is ({x}, {y})&lt;/h1&gt;<br> )} /&gt;<br> );<br>}</blockquote><p>5. <strong>Container and Presentational Components</strong><br>A pattern that separates the logic (Container) from the UI (Presentational) in components. Presentational components are concerned with how things look, while Containers manage the data and state.</p><blockquote>Example:<br>// Presentational Component<br>function TodoList({ todos, onTodoClick }) {<br> return (<br> &lt;ul&gt;<br> {todos.map(todo =&gt; (<br> &lt;li key={todo.id} onClick={() =&gt; onTodoClick(todo.id)}&gt;<br> {todo.text}<br> &lt;/li&gt;<br> ))}<br> &lt;/ul&gt;<br> );<br>}</blockquote><blockquote>// Container Component<br>class TodoListContainer extends React.Component {<br> state = { todos: [] };</blockquote><blockquote>componentDidMount() {<br> // Fetch data here<br> this.setState({<br> todos: [<br> { id: 1, text: ‘Learn React’ },<br> { id: 2, text: ‘Practice Coding’ },<br> ],<br> });<br> }</blockquote><blockquote>handleTodoClick = (id) =&gt; {<br> console.log(‘Todo clicked:’, id);<br> };</blockquote><blockquote>render() {<br> return (<br> &lt;TodoList<br> todos={this.state.todos}<br> onTodoClick={this.handleTodoClick}<br> /&gt;<br> );<br> }<br>}</blockquote><p>6. <strong>Compound Components</strong><br>A pattern where components work together to manage internal state and communicate with each other, often used for UI libraries (e.g., forms, tabs).</p><blockquote>Example:<br>function Tabs({ children }) {<br> const [activeIndex, setActiveIndex] = React.useState(0);</blockquote><blockquote>return (<br> &lt;div&gt;<br> &lt;div&gt;<br> {children.map((child, index) =&gt; (<br> &lt;button key={index} onClick={() =&gt; setActiveIndex(index)}&gt;<br> {child.props.label}<br> &lt;/button&gt;<br> ))}<br> &lt;/div&gt;<br> &lt;div&gt;{children[activeIndex]}&lt;/div&gt;<br> &lt;/div&gt;<br> );<br>}</blockquote><blockquote>function Tab({ children }) {<br> return &lt;div&gt;{children}&lt;/div&gt;;<br>}</blockquote><blockquote>function App() {<br> return (<br> &lt;Tabs&gt;<br> &lt;Tab label=”Tab 1&quot;&gt;Content of Tab 1&lt;/Tab&gt;<br> &lt;Tab label=”Tab 2&quot;&gt;Content of Tab 2&lt;/Tab&gt;<br> &lt;Tab label=”Tab 3&quot;&gt;Content of Tab 3&lt;/Tab&gt;<br> &lt;/Tabs&gt;<br> );<br>}</blockquote><p>7. <strong>Controlled and Uncontrolled Components</strong><br>Controlled Components: Form elements where React controls the value through state.<br>Uncontrolled Components: Form elements where the DOM manages the value, accessed via refs.</p><blockquote>Example:<br>// Controlled Component<br>function ControlledInput() {<br> const [value, setValue] = React.useState(‘’);</blockquote><blockquote>return (<br> &lt;input<br> type=”text”<br> value={value}<br> onChange={(e) =&gt; setValue(e.target.value)}<br> /&gt;<br> );<br>}</blockquote><blockquote>// Uncontrolled Component<br>function UncontrolledInput() {<br> const inputRef = React.useRef();</blockquote><blockquote>return &lt;input type=”text” ref={inputRef} /&gt;;<br>}</blockquote><p>8. <strong>Custom Hooks</strong><br>A way to extract and reuse logic in functional components using React hooks.</p><blockquote>Example:<br>function useCounter(initialValue = 0) {<br> const [count, setCount] = React.useState(initialValue);</blockquote><blockquote>const increment = () =&gt; setCount(count + 1);<br> const decrement = () =&gt; setCount(count — 1);</blockquote><blockquote>return { count, increment, decrement };<br>}</blockquote><blockquote>function Counter() {<br> const { count, increment, decrement } = useCounter();</blockquote><blockquote>return (<br> &lt;div&gt;<br> &lt;p&gt;Count: {count}&lt;/p&gt;<br> &lt;button onClick={increment}&gt;+&lt;/button&gt;<br> &lt;button onClick={decrement}&gt;-&lt;/button&gt;<br> &lt;/div&gt;<br> );<br>}</blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f0cb50e3e38f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Sneak Peek at Devika: The AI Software Engineer Agent]]></title>
            <link>https://medium.com/@bnshah.dev/sneak-peek-at-devika-the-ai-software-engineer-agent-50ccf63d2877?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/50ccf63d2877</guid>
            <category><![CDATA[devika]]></category>
            <category><![CDATA[genai]]></category>
            <category><![CDATA[ai]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Sun, 07 Apr 2024 20:29:12 GMT</pubDate>
            <atom:updated>2024-04-07T20:29:12.651Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Github</strong>: <a href="https://github.com/stitionai/devika">https://github.com/stitionai/devika</a></p><p><strong>Setup</strong> (complexity — easy):</p><p>Major dependancies -</p><ul><li>Python</li><li>Bun</li><li>UV</li><li>Ollama</li></ul><p><strong>Models</strong> supported:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eicQPusSgyHJpACB88kR9A.png" /></figure><p><strong>Search Engines </strong>supported:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*f7zFbVeGBZGf-9QzVr_QPA.png" /></figure><p><strong>Prompt</strong>:<br><em>Write a javascript script to print numbers 1 to 100.</em></p><p><strong>Devika Action</strong>:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9mX7dnGA0e8tAgHycr_hWw.png" /><figcaption>Devika in Action</figcaption></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=50ccf63d2877" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Trace / Log all API calls made by axios]]></title>
            <link>https://medium.com/@bnshah.dev/trace-api-calls-made-by-axios-2e1e3bc4ced5?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/2e1e3bc4ced5</guid>
            <category><![CDATA[axios]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Thu, 17 Jun 2021 09:30:12 GMT</pubDate>
            <atom:updated>2021-06-20T09:22:28.636Z</atom:updated>
            <content:encoded><![CDATA[<p>When someone asks me, what API call is made on this click? and I am relatively new to the React project/code..</p><p><strong>Setup -</strong></p><ol><li>Add npm package axios curlirize</li></ol><pre>npm i --save axios-curlirize@latest</pre><p>2. In service file / entry file of axios</p><pre> <strong>import</strong> axios <strong>from</strong> ‘axios’;<br> curlirize(axios);</pre><p>3. Well I just need logs on debug mode</p><p>React Native-</p><pre><strong>import</strong> axios <strong>from</strong> ‘axios’;<br>if(__DEV__) curlirize(axios);</pre><p>React -</p><pre><strong> import</strong> axios <strong>from</strong> ‘axios’;<br> if(process.env.NODE_ENV === “development”) curlirize(axios);</pre><p>Now I click on that button, get CURL from console and pass it away!</p><p>Thanks!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2e1e3bc4ced5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Run cypress test suit regularly with cloud function]]></title>
            <link>https://medium.com/@bnshah.dev/run-cypress-test-suit-regularly-with-cloud-function-bf922147f6f1?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/bf922147f6f1</guid>
            <category><![CDATA[cloud-functions]]></category>
            <category><![CDATA[cypress]]></category>
            <category><![CDATA[google-cloud-build]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Thu, 17 Jun 2021 08:18:44 GMT</pubDate>
            <atom:updated>2021-06-17T08:18:44.909Z</atom:updated>
            <content:encoded><![CDATA[<p>Just very high level / brief thought to have extra layer of quality check.</p><p><strong>Setup —</strong></p><ol><li>Have a separate git repository for cypress tests</li><li>Have a Google cloud setup to access Google cloud build Triggers and Google cloud functions</li><li>Have a access to cypress dashboard to see statistics of Cypress test suits results</li></ol><p><strong>Steps —</strong></p><ol><li>Create Google cloud build trigger — with trigger type incoming web-hook and create required .yaml file</li><li>Create a cloud a function / pubsub scheduler specifying frequency of execution and call cloud build trigger web-hook within</li><li>Get updated statistics on cypress dashboard</li></ol><p>Thanks!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bf922147f6f1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to keep the App location ready with iOS 14 permission changes]]></title>
            <link>https://medium.com/@bnshah.dev/how-to-keep-the-app-location-ready-with-ios-14-permission-changes-7cea859a5fc2?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/7cea859a5fc2</guid>
            <category><![CDATA[core-location]]></category>
            <category><![CDATA[ios-14]]></category>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[xcode-12]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Sat, 29 Aug 2020 19:03:53 GMT</pubDate>
            <atom:updated>2020-08-29T19:15:27.597Z</atom:updated>
            <content:encoded><![CDATA[<h3>iOS 14 permission changes: How to keep the App location-ready?</h3><p>With iOS 14, Apple is adding a new dimension into the location permission flow, giving further control to the users — at what extent they want to be tracked by the App :)</p><p>So far - before iOS 14, users were given choice to allow location access from their device only on based on the WHEN factor but now taking it to next level there are more choices users can make — App should access my accurate location or precise location?</p><p>Starting with iOS 14, on requesting location access, prompt will be updated as:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/282/1*-nxsXcRG6LRIArHq_fOV5g.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/282/1*Pn80hIC3KwZokddPB64HiQ.png" /><figcaption>User given choice to toggle precision of location</figcaption></figure><p><strong>What will happen to existing Apps/Users, by upgrading to iOS 14?</strong></p><ul><li>By default, location service will be upgraded to have a precise location set to ON.</li><li>In the device’s Settings app, the user will have the option to turn off precise location — so that App will get only approximate locations.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/563/1*I0NXESmFau-aFmvQRfF9oA.png" /></figure><ul><li>Apps — which are location critical might get in trouble if the user sets the precise location to OFF (intentionally or unintentionally) &amp; App does not tackle it.</li></ul><p><strong>What code changes are required to handle new permission?</strong></p><ul><li>If the location of the device is crucial for the App, It should be aware of it is getting an accurate location or not? And if not, it must do something about it to keep business flow intact.</li></ul><pre>//check for accuracy<br><strong>if</strong> <strong>let</strong> accuracyStatus = locationManager?.accuracyAuthorization {<br>  <strong>if</strong>(accuracyStatus == .reducedAccuracy) {<br>     promptUserForAccuracy()<br>   }<br>}</pre><p><strong>Note — </strong>accuracyAuthorization<strong>, </strong>authorizationStatus now part of instance member, not class one</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/281/1*kk6R-mYFbOlHQfsdYlTG-g.png" /><figcaption>Prompt when App is not allowed to use precise location</figcaption></figure><p><strong>Respect user privacy, ask for accuracy for a specific purpose/feature!</strong></p><ul><li>Now, if the App does not require an exact location for all of its features, but it is required to have accurate one only for specific features (i.e during checkout, booking service, etc) — then App may ask for temporary accuracy level for that session only.</li><li>For different features, different prompt message (purpose key) can be set in .plist file</li></ul><pre><strong>&lt;key&gt;</strong>NSLocationTemporaryUsageDescriptionDictionary<strong>&lt;/key&gt;<br>&lt;dict&gt;</strong></pre><pre><strong> &lt;key&gt;</strong>AccuracyFeatureFirst<strong>&lt;/key&gt;<br> &lt;string&gt;</strong>This app needs accurate location so it can verify that you’re in a supported region.<br><strong>&lt;/string&gt;  <br>  <br> &lt;key&gt;</strong>AccuracyFeatureSecond<strong>&lt;/key&gt;<br> &lt;string&gt;</strong>This app needs accurate location so it can show you relevant results.<br><strong>&lt;/string&gt;</strong></pre><pre><strong>&lt;/dict&gt;</strong></pre><ul><li>Once .plist file is updated with NSLocationTemporaryUsageDescriptionDictionary, it can be requested with an instance method, and desired purpose key —</li></ul><pre>//AccuracyFeatureFirst</pre><pre><strong>if</strong> <strong>let</strong> accuracyStatus = locationManager?.accuracyAuthorization {<br> <strong>if</strong>(accuracyStatus == .reducedAccuracy){<br> locationManager?.requestTemporaryFullAccuracyAuthorization(withPurposeKey: “AccuracyFeatureFirst”, completion: { (error) <strong>in <br>  </strong>print(“error -&gt; \(error.debugDescription)”)<br>  })<br> }<br>}<br></pre><pre>//AccuracyFeatureSecond</pre><pre><strong>if</strong> <strong>let</strong> accuracyStatus = locationManager?.accuracyAuthorization {<br> <strong>if</strong>(accuracyStatus == .reducedAccuracy){<br> locationManager?.requestTemporaryFullAccuracyAuthorization(withPurposeKey: “AccuracyFeatureSecond”, completion: { (error) <strong>in <br>  </strong>print(“error -&gt; \(error.debugDescription)”)<br>  })<br> }</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/450/1*mziTPauU7625IwqzBsqOpw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/281/1*-bXPlEHNb6Vu2l6tdER-QQ.png" /><figcaption>Prompt when App asks for full accuracy temporarily</figcaption></figure><p><strong>Source code — </strong><br><a href="https://github.com/bnshahdev/iOS14LocationOnBoard">https://github.com/bnshahdev/iOS14LocationOnBoard</a></p><p>Happy Tracking!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7cea859a5fc2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[let redux-saga do the fetch]]></title>
            <link>https://medium.com/@bnshah.dev/let-redux-saga-do-the-fetch-ac6accacd423?source=rss-467dfe480b0d------2</link>
            <guid isPermaLink="false">https://medium.com/p/ac6accacd423</guid>
            <category><![CDATA[react-redux]]></category>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[redux-saga]]></category>
            <category><![CDATA[redux]]></category>
            <dc:creator><![CDATA[Bhavik Shah]]></dc:creator>
            <pubDate>Sun, 23 Aug 2020 18:28:00 GMT</pubDate>
            <atom:updated>2020-08-27T17:22:09.314Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to use redux-saga middleware for GET request</h3><p>Many of the React Native Apps might start with no app-level state container, <br>then upgraded to have state container redux, <br>then upgraded to have middleware redux-saga — to have more control (side effects) and flexibility of unit tests!</p><p>Once redux-saga has been successfully integrated, App would be leveraging maximum out of its features. Let’s go through one of the primary/basics/often required use case — GET the data!</p><p><strong>Ingredients</strong> — <br>1) The redux, redux-saga packages are already installed, and ready to use.<br>2) A class component, which requires data from server/backend.</p><p><strong>Recipe</strong> —</p><ol><li>Setup App.js</li></ol><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/57e9e7fbc731dbd1ab4272b433dd88ee/href">https://medium.com/media/57e9e7fbc731dbd1ab4272b433dd88ee/href</a></iframe><p>2. Prepare a class component, which can communicate with redux container</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/03da8eafd3054de93fc799f92ed3cfc9/href">https://medium.com/media/03da8eafd3054de93fc799f92ed3cfc9/href</a></iframe><p>3. Call an action</p><pre>this.props.fetchSummary();</pre><p>Actions.js</p><pre>import * as actions from “../../actions/actions”;</pre><pre>export function fetchSummary() {<br>  return {<br>    type: actions.FETCH_SUMMARY,<br>    payload: “”,<br> };<br>}</pre><p>4. Intercept called action, do the saga!</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/537d0992d86f9727dee576494b1ac359/href">https://medium.com/media/537d0992d86f9727dee576494b1ac359/href</a></iframe><pre>export const getSummary = () =&gt; {<br>   return axios.get(“https://api.covid19api.com/summary&quot;);<br>};</pre><p>5. Confirm the class component re-renders</p><pre>componentDidUpdate(prevProps, prevState) {</pre><pre>  console.log(“this.props.globalData -&gt;” + this.props.globalData);<br>  console.log(“this.props.countryData -&gt;” + this.props.countryData.length);</pre><pre>}</pre><p><strong>When it works —</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*Hp5Wje5AgUnYEZioaOMumA.png" /><figcaption>Thanks to covid19api.com</figcaption></figure><p><strong>Source code</strong> — <br><a href="https://github.com/bnshahdev/reduxSagaOnboard">https://github.com/bnshahdev/reduxSagaOnboard</a></p><p>Happy Fetching!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ac6accacd423" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>