<?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 hendri on Medium]]></title>
        <description><![CDATA[Stories by hendri on Medium]]></description>
        <link>https://medium.com/@h_firmana?source=rss-12427955e517------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/proxy/1*TGH72Nnw24QL3iV9IOm4VA.png</url>
            <title>Stories by hendri on Medium</title>
            <link>https://medium.com/@h_firmana?source=rss-12427955e517------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 09:22:45 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@h_firmana/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[How Pain I Upgraded React Native]]></title>
            <link>https://medium.com/@h_firmana/how-pain-i-upgraded-react-native-caa691c95f9e?source=rss-12427955e517------2</link>
            <guid isPermaLink="false">https://medium.com/p/caa691c95f9e</guid>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[solo-developer]]></category>
            <dc:creator><![CDATA[hendri]]></dc:creator>
            <pubDate>Thu, 24 Jul 2025 16:51:53 GMT</pubDate>
            <atom:updated>2025-07-24T16:51:53.135Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>A solo full‑stack developer’s tale of dragging an 8‑year‑old legacy mobile app to Google Play’s 2025 target API level (35).</strong></p><blockquote><strong>TL;DR</strong>: Inheriting an 8‑year‑old React Native app with poor documentation and dozens of stale dependencies, I had to meet Google Play’s annual target API level bump (API 35 for 2025). Incremental in‑place upgrades from React Native 0.71 → 0.75 repeatedly failed due to cascading Android + library compatibility breaks (Gradle, AGP, Hermes, New Architecture toggles, and library churn: react-native-vector-icons, react-native-gesture-handler, react-native-reanimated, etc.). I eventually spun up a fresh project on the latest RN, migrated features in slices, and regained control. It was slower up front, faster to sanity. If you’re a solo dev: schedule refactor windows, automate smoke tests, and seriously consider when native Kotlin/Swift may be cheaper long‑term.</blockquote><h3>Point of View / Context</h3><p>Last year I inherited a <strong>legacy React Native codebase</strong> that first shipped roughly <strong>8 years ago</strong>. There was <strong>no documentation </strong>from previous developer, uneven patterns across features, conditional logic sprinkled throughout platform files, and build scripts that assumed long‑deprecated tooling.</p><p>I’m a <strong>full‑stack developer</strong> responsible for <em>everything :-D,</em> the <strong>web app</strong> that stakeholders use,<strong> </strong>the mobile app used by field operators in certain continents, and a <strong>WordPress </strong>for certain customer that consumes the same backend API stack with mobile. Mobile is important, but it’s <strong>not my only job</strong> — which meant I’ve been adding features and applying “drive‑by refactors” whenever emergencies hit, not doing a clean architectural overhaul.</p><p>Sound familiar?</p><h3>The Email That Lit the Fire</h3><blockquote><strong><em>Subject:</em></strong><em> Important message — Your app is affected by Google Play’s target API level requirements.</em></blockquote><p>If you’ve shipped Android apps, you know what’s coming: <strong>each year Google Play ratchets up the minimum target API level you must meet</strong> to keep full distribution. If you don’t update in time, new installs for users on newer Android versions get restricted.</p><ul><li>In 2024 we scrambled to reach <strong>target API 34</strong>. I pulled that off — barely — by nudging build tooling (Gradle 7.5.1) and patching dependencies without fully upgrading React Native;</li><li>For <strong>2025</strong>, Google Play wants <strong>target API level 35</strong>. That’s when everything broke.</li></ul><h3>Where I Started: React Native 0.71 (Classic Architecture, Bridge World)</h3><p>The legacy codebase was pinned to <strong>React Native 0.71</strong>:</p><ul><li><strong>Classic (bridge) architecture by default;</strong></li><li><strong>New Architecture (Fabric + TurboModules)</strong> exists but is opt‑in and experimental;</li><li><strong>Hermes</strong> is available but not required;</li><li>Most third‑party libraries still assume the old bridge path.</li></ul><p>Android build config was a pile of hand‑edited Gradle files. We were technically targeting API 33, but we pushed it to 34 the previous year with a messy upgrade that didn’t touch React Native itself.</p><h3>The Road to API 35: Two Experiments</h3><p>When the 2025 deadline landed, I evaluated <strong>two upgrade strategies</strong>:</p><ol><li><strong>In‑place upgrade</strong>: move the legacy app from RN 0.71 → 0.75 (and beyond), updating dependencies along the way;</li><li><strong>Clean‑room rebuild</strong>: generate a fresh, up‑to‑date React Native project (I used the latest version available — call it <em>RN Latest</em>, ~0.8x at the time), then migrate my app’s code in controlled chunks.</li></ol><p>Below is what happened.</p><h3>Path 1: In‑Place Upgrade (RN 0.71 → 0.75) — Death by a Thousand Cuts</h3><p>I started conservatively: keep the existing repo, run npx react-native upgrade, follow the interactive diff prompts, and bump version numbers in package.json + Gradle.</p><h3>What I Did</h3><ul><li>Updated <strong>React Native</strong> to 0.75.x;</li><li>Updated React Native packages to be compatible with React Native 0.75.x, for example following guidance to upgrade react-native-gesture-handlerfrom this link <a href="https://docs.swmansion.com/react-native-gesture-handler/docs/fundamentals/installation/">https://docs.swmansion.com/react-native-gesture-handler/docs/fundamentals/installation/</a>;</li><li>Bumped <strong>Android Gradle Plugin (AGP)</strong> and <strong>Gradle wrapper</strong> (eventually testing 7.6+);</li><li>Set compileSdkVersion = 35 and targetSdkVersion = 35;</li><li>Updated Kotlin Gradle plugin where required’</li><li>Reinstalled Android build tools + SDK 35;</li><li>Tried to align library versions with the compatibility matrices in various READMEs/issues.</li></ul><h3>Immediate Breakage</h3><p>Builds failed fast — and differently — depending on the order I upgraded things. Highlights:</p><pre>| Package                        | Failure Mode                                           | Notes                                                           |<br>| ------------------------------ | ------------------------------------------------------ | --------------------------------------------------------------- |<br>| `react-native-vector-icons`    | Resource merge / duplicate fonts / namespace conflicts | Legacy manual linking collided with autolinking.                |<br>| `react-native-gesture-handler` | Missing AndroidX refs / outdated Gradle plugin hooks   | Needed version sync + cleanup of old MainActivity registration. |<br>| `react-native-reanimated`      | CMake / NDK / JSI symbol issues under newer RN         | Version range tied to specific RN + Hermes combos.              |</pre><p>Every patch fixed one error and revealed two more. Some libraries wanted New Architecture flags; others broke <em>with</em> them. Some assumed Hermes; others had handwritten ProGuard rules incompatible with newer R8 versions.</p><h3>Why I Abandoned This Path</h3><ul><li><strong>Cascading dependency churn</strong> with no end in sight;</li><li><strong>Unclear library support windows</strong> — docs lag actual releases;</li><li><strong>No full automated test suite</strong> to prove functional stability after merges;</li><li><strong>Time pressure</strong>: I still had to maintain the web platform.</li></ul><p>After multiple rounds of patch‑build‑fail, I paused. If you’ve got a clean, well‑tested app, in‑place may work. Mine was not that.</p><h3>Path 2: Clean‑Room Rebuild on Latest React Native — The Reset Button</h3><p>I decided to create a <strong>brand‑new React Native project</strong> using the community CLI and then <strong>migrate the </strong><strong>src directory and key components</strong> from the old codebase into this fresh skeleton. This was both liberating and <strong>brutally painful</strong> because it exposed just how many inconsistencies had built up over eight years.</p><pre>npx @react-native-community/cli init MyApp --version latest</pre><p>This setup provided:</p><ul><li><strong>Latest React Native (~0.8x)</strong>.</li><li><strong>New Architecture enabled by default</strong> (Fabric + TurboModules).</li><li><strong>Hermes as the default JS engine.</strong></li><li>Up‑to‑date <strong>Gradle/AGP/Kotlin</strong> stack.</li><li>Modern Android + iOS templates with fewer legacy hacks.</li></ul><h3>Migration Strategy</h3><p>I treated the old repo as a <strong>code quarry</strong>, pulling in only what was necessary and rewriting where required. The process looked like this:</p><ol><li><strong>Core utilities and types</strong> (constants, API clients, helpers);</li><li><strong>Authentication flow;</strong></li><li><strong>Navigation shell</strong> (migrating directly to the latest React Navigation + gesture handler);</li><li><strong>Feature modules</strong>, one at a time, deciding whether to port or rewrite;</li><li><strong>Native modules</strong>, replacing outdated ones with maintained alternatives.</li></ol><h3>Upgrade === Re-write</h3><p>This approach highlighted how <strong>upgrades weren’t smooth but forced rewrites</strong>, often due to API changes. For instance:</p><pre>// Old OneSignal Initialization<br>OneSignal.initApp(&quot;xxxxxxxxxx&quot;);<br><br>// New OneSignal Initialization<br>OneSignal.initialize(&quot;xxxxxxxxxx&quot;);</pre><p>It might seem trivial, but these small breaking changes stacked up across libraries like OneSignal, gesture handling, and analytics. Each required careful review and testing.</p><h3>Why I Choose Second Choice</h3><ul><li><strong>Clean baseline</strong> with modern templates that already meet Google Play API requirements;</li><li><strong>No legacy clutter</strong> from outdated configs;</li><li><strong>Clearer progress and control in our hand</strong>: if something failed, I knew exactly where;</li><li><strong>Opportunity to modernize</strong>: hooks instead of classes, TypeScript strengthening, improved error boundaries, removing old redux with redux toolkit, etc.</li></ul><h3>Trade‑Offs</h3><ul><li><strong>High upfront rework</strong> and learning curve;</li><li><strong>Risk of regressions</strong> from overlooked edge cases;</li><li><strong>Temporary double maintenance</strong> between the old and new app.</li></ul><p>Still, this was less stressful than the endless struggle of patching an outdated codebase.</p><h3><strong>Architecture Evolution Snapshot</strong></h3><pre><br>| Version         | Architecture Default             | Hermes   | Library Ecosystem                    | Notes                                            |<br>|-----------------|----------------------------------|----------|--------------------------------------|--------------------------------------------------|<br>| RN 0.71         | Classic bridge                   | Optional | Most libs still bridge‑centric       | New Arch experimental; many libs untested.       |<br>| RN 0.75         | Classic (New Arch opt‑in)        | Better   | More libs supporting Fabric/Turbo    | Transitional friction; mixed expectations.       |<br>| RN Latest(~0.8x)| New Arch ON by default           | Default  | Majority adapting                    | Better interop, perf gains, React 19 aligned.    |</pre><h3>Lessons Learned (Solo Dev Edition)</h3><p><strong>1. Put upgrade time on the roadmap.</strong> If you don’t, the platform owner will do it for you — on their schedule.</p><p><strong>2. Reduce packages dependencies.</strong> Every abandoned library becomes your problem.</p><p><strong>3. Document as you go.</strong> Today’s “quick fix” is tomorrow’s archaeology dig.</p><p><strong>4. Consider native when platform drift dominates.</strong> If your app is heavy on device‑level features and you’re the only JS dev, <strong>a Kotlin (Android) + SwiftUI (iOS) rewrite may actually be <em>less</em> painful long‑term</strong> than dragging dead React Native code through yearly SDK bumps.</p><p><em>Coming up: the iOS migration challenges and how they compared.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=caa691c95f9e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Versioning Manager Menggunakan asdf]]></title>
            <link>https://medium.com/@h_firmana/versioning-manager-menggunakan-asdf-a6ba17569fcf?source=rss-12427955e517------2</link>
            <guid isPermaLink="false">https://medium.com/p/a6ba17569fcf</guid>
            <category><![CDATA[ruby]]></category>
            <category><![CDATA[rbenv]]></category>
            <category><![CDATA[bash-script]]></category>
            <category><![CDATA[asdf]]></category>
            <dc:creator><![CDATA[hendri]]></dc:creator>
            <pubDate>Tue, 26 Jun 2018 04:00:56 GMT</pubDate>
            <atom:updated>2018-06-26T06:26:03.534Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*R643FD0_N3VZRFawvPEo9Q.jpeg" /><figcaption><a href="https://cdnb.artstation.com/p/assets/images/images/005/629/885/large/jake-gilmore-asdf-final.jpg?1492588014">https://cdnb.artstation.com/p/assets/images/images/005/629/885/large/jake-gilmore-asdf-final.jpg?1492588014</a></figcaption></figure><p>Mungkin bagi kawan-kawan dari komunitas ruby sudah tidak asing lagi dengan version managment tool bernama <a href="https://rvm.io/">RVM</a> yang overkill atau <a href="https://github.com/rbenv/rbenv">rbenv</a> dengan simplicity-nya, bagi saya tools tersebut terutama rbenv sangat berguna sekali untuk melakukan management versi dari ruby beserta gems-nya, mengingat masih ada aplikasi Ruby yang masih harus di-<em>maintain</em><br>pada 1.8.7, 1.9.2 sampai ruby yang versi diatas 2.0.0.</p><p><strong><em>life is change</em></strong>, seiring dengan kebutuhan version management, saya membutuhkan sebuah tool yang <strong><em>cross language</em></strong> <br>dan tidak tergantung pada environment satu language saja, akhirnya pilihan saya jatuh pada <a href="https://github.com/asdf-vm/asdf"><strong>asdf</strong></a>, buat saya asdf itu adalah <strong><em>bash script bundle</em></strong> untuk management version.</p><h3>Install</h3><p>untuk mencobanya langsung saja kita install, asumsi untuk proses instalasi adalah telah terinstall Ubuntu, GIT dan zsh (oh-my-zsh) :</p><pre>git clone <a href="https://github.com/asdf-vm/asdf.git">https://github.com/asdf-vm/asdf.git</a> ~/.asdf — branch v0.5.0</pre><p>proses diatas adalah melakukan <strong><em>clone</em></strong> dari repository code yang terdapat di <a href="http://github.com/">github</a> dengan branch version release-nya di v0.5.0, codenya ditempatkan di folder default $HOME di .asdf. folder itulah yang akan dipakai sebagai folder default dari asdf.</p><pre>echo -e ‘\n. $HOME/.asdf/asdf.sh’ &gt;&gt; ~/.zshrc<br>echo -e ‘\n. $HOME/.asdf/completions/asdf.bash’ &gt;&gt; ~/.zshrc</pre><p>jika menggunakan oh-my-zsh bisa ditambahkan dengan menggunakan perintah di atas kedalam file .<strong>zshrc</strong></p><pre>sudo apt install automake autoconf libreadline-dev libncurses-dev libssl-dev libyaml-dev libxslt-dev libffi-dev libtool unixodbc-dev</pre><p>untuk ubuntu bisa ditambahkan <strong><em>packages</em></strong> tambahan dengan perintah di atas</p><h3>Penggunaan</h3><p>untuk penggunaan saya asumsikan kita akan menginstall Ruby,</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/879/1*bFUDURfacubFHhtoIiaxug.png" /><figcaption>Gambar tampilan asdf setelah berhasil diinstall</figcaption></figure><p>selanjutnya saya ingin menambahkan, ruby ke dalam list language yang akan diinstall, untuk mengecek list plugin dapat dilihat infonya di <a href="https://github.com/asdf-vm/asdf-plugins"><strong><em>https://github.com/asdf-vm/asdf-plugins</em></strong></a></p><pre>asdf plugin-add &lt;name&gt; &lt;git-url&gt; // <br>asdf plugin-add ruby <a href="https://github.com/asdf-vm/asdf-ruby.git">https://github.com/asdf-vm/asdf-ruby.git</a></pre><p>setelah plugin berhasil ditambahkan</p><pre>asdf plugin-list</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/489/1*m4uE3TvZzY_HxeXXPvtZgA.png" /><figcaption>tampilan plugin list di terminal saya</figcaption></figure><pre>asdf install &lt;name&gt; &lt;version&gt;<br>asdf install ruby 2.4.2<br>asdf global ruby 2.4.2 // set ruby versi ini sebagai global<br>ruby -v // cek versi ruby sebagai global<br>ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-linux]</pre><p>eksekusi perintah di atas di command line</p><pre>$HOME/.asdf/installs/ruby //letak ruby dan gems berada folder ini</pre><p>selanjutnya untuk detailnya bisa dibaca di redme repository-nya.</p><p><strong><em>Happy</em></strong> <strong><em>Coding!!!.</em></strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a6ba17569fcf" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>