<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Alaa Qadomy</title>
    <description>The latest articles on DEV Community by Alaa Qadomy (@alaa_qadomy_d13dfc9fa189f).</description>
    <link>https://dev.to/alaa_qadomy_d13dfc9fa189f</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4222495%2Fd136e319-27c6-4bfd-ad04-0c85a821862a.png</url>
      <title>DEV Community: Alaa Qadomy</title>
      <link>https://dev.to/alaa_qadomy_d13dfc9fa189f</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/alaa_qadomy_d13dfc9fa189f"/>
    <language>en</language>
    <item>
      <title>One codebase, two outputs: a zero-dependency static site and an Android app for Quran audio</title>
      <dc:creator>Alaa Qadomy</dc:creator>
      <pubDate>Mon, 02 Nov 2026 13:46:13 +0000</pubDate>
      <link>https://dev.to/alaa_qadomy_d13dfc9fa189f/one-codebase-two-outputs-a-zero-dependency-static-site-and-an-android-app-for-quran-audio-58aj</link>
      <guid>https://dev.to/alaa_qadomy_d13dfc9fa189f/one-codebase-two-outputs-a-zero-dependency-static-site-and-an-android-app-for-quran-audio-58aj</guid>
      <description>&lt;p&gt;I built a Quran audio project where the same JavaScript generates both a static website and an Android app, with no runtime dependencies in the generator. Here is how it is structured and what I would do again.&lt;/p&gt;

&lt;p&gt;The result is called &lt;a href="https://suwar-quran.web.app/" rel="noopener noreferrer"&gt;Suwar&lt;/a&gt;: one page per surah, in Arabic and English.&lt;/p&gt;

&lt;h2&gt;
  
  
  The constraint
&lt;/h2&gt;

&lt;p&gt;I wanted every one of the 114 surahs to have its own indexable page, in two languages, plus a mobile app that reuses the same interface. That is 228 pages. I did not want a framework build step to maintain for something this simple.&lt;/p&gt;

&lt;h2&gt;
  
  
  The structure
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Data&lt;/strong&gt;: a fetch script pulls the text once and validates it (114 surahs, 6,236 verses) before anything is generated. If the counts are off, the build stops.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Generator&lt;/strong&gt;: plain Node.js, no dependencies. It writes one HTML file per surah per language, plus a sitemap, &lt;code&gt;hreflang&lt;/code&gt; alternates, JSON-LD, and an &lt;code&gt;llms.txt&lt;/code&gt; file.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;App&lt;/strong&gt;: Capacitor wraps the same built UI as an Android project. The audio player uses MediaSession (repeat, speed, sleep timer, resume).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Tests&lt;/strong&gt;: run with Node and a headless Chromium, so the generator can be checked without an Android SDK.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What worked
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Validating data before generating.&lt;/strong&gt; A wrong verse count fails the build instead of shipping bad pages.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Keeping the generator dependency-free.&lt;/strong&gt; It runs anywhere Node runs, which mattered because I develop on a machine where package installs are not always possible.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;One UI for web and app.&lt;/strong&gt; Fixes land once.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  What I would watch for
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Attribution and licensing: the text comes from &lt;a href="https://tanzil.net" rel="noopener noreferrer"&gt;Tanzil&lt;/a&gt; under CC BY 3.0, so the source must be credited and the text must not be modified.&lt;/li&gt;
&lt;li&gt;Audio rights are separate from text rights. Each reciter is configured with a &lt;code&gt;licensed&lt;/code&gt; flag so that any of them can be removed at once.&lt;/li&gt;
&lt;li&gt;Ads: a small banner on regular screens and an optional rewarded ad. None during playback.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you build content sites with many near-identical pages, the validate-then-generate pattern is the part worth copying.&lt;/p&gt;

</description>
      <category>android</category>
      <category>javascript</category>
      <category>seo</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
