<?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: Choudhary yousaf</title>
    <description>The latest articles on DEV Community by Choudhary yousaf (@choudhary_yousaf_e5d94b40).</description>
    <link>https://dev.to/choudhary_yousaf_e5d94b40</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%2F4246345%2Fc68d3e5c-62a7-4a00-bf43-7ade857e68c1.png</url>
      <title>DEV Community: Choudhary yousaf</title>
      <link>https://dev.to/choudhary_yousaf_e5d94b40</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/choudhary_yousaf_e5d94b40"/>
    <language>en</language>
    <item>
      <title>I built 20 calculators that show their working. Here's the stack, the bugs and the SEO surprise</title>
      <dc:creator>Choudhary yousaf</dc:creator>
      <pubDate>Sun, 15 Nov 2026 17:55:03 +0000</pubDate>
      <link>https://dev.to/choudhary_yousaf_e5d94b40/i-built-20-calculators-that-show-their-working-heres-the-stack-the-bugs-and-the-seo-surprise-3ef6</link>
      <guid>https://dev.to/choudhary_yousaf_e5d94b40/i-built-20-calculators-that-show-their-working-heres-the-stack-the-bugs-and-the-seo-surprise-3ef6</guid>
      <description>&lt;p&gt;Most online calculators give you a number and expect you to trust it. I wanted the opposite: under every result, a line that prints the exact sum with your numbers in it, so you can check it by hand.&lt;/p&gt;

&lt;p&gt;That became &lt;a href="https://ezisolutions.online" rel="noopener noreferrer"&gt;EziSolutions&lt;/a&gt;, a free site with 20 calculators: Etsy, Mercari, Poshmark, Venmo, Stripe, Square and Fiverr fees, ROAS, customer LTV, CPM, BMI, TDEE, VAT, loans, freelance rates and a few more. No framework, no backend, no signup.&lt;/p&gt;

&lt;p&gt;Here's how it's built, the bugs that taught me something, and an honest look at the SEO side, which didn't go the way I expected.&lt;/p&gt;

&lt;p&gt;I built it with help from an AI coding assistant, and checked every formula and fee myself.&lt;/p&gt;

&lt;h2&gt;
  
  
  The stack (deliberately boring)
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Python build script.&lt;/strong&gt; &lt;code&gt;content.py&lt;/code&gt; holds every page as data: title, description, form fields, the explanation, FAQs and sources. &lt;code&gt;build.py&lt;/code&gt; turns it into plain HTML files in &lt;code&gt;public/&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Vanilla JavaScript.&lt;/strong&gt; One &lt;code&gt;tools.js&lt;/code&gt; file with one function per calculator. No React, no bundler.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cloudflare Workers with static assets.&lt;/strong&gt; The Worker just serves &lt;code&gt;public/&lt;/code&gt;. &lt;code&gt;_headers&lt;/code&gt; sets security headers and &lt;code&gt;_redirects&lt;/code&gt; handles old URLs.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GitHub + Workers Builds.&lt;/strong&gt; Every push to &lt;code&gt;main&lt;/code&gt; runs &lt;code&gt;npx wrangler deploy&lt;/code&gt;. About 40 seconds from &lt;code&gt;git push&lt;/code&gt; to live.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The whole deploy config is this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json-doc"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"name"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"icy-shape-8ab9"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"compatibility_date"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"2026-11-01"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"assets"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"directory"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"./public"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"not_found_handling"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"404-page"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nl"&gt;"html_handling"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"auto-trailing-slash"&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"routes"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"pattern"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"ezisolutions.online"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"custom_domain"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"pattern"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"www.ezisolutions.online"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"custom_domain"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"workers_dev"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I commit the built &lt;code&gt;public/&lt;/code&gt; folder instead of building on Cloudflare. It's less elegant, but the deploy step has nothing to break, and I can see exactly what ships in every diff.&lt;/p&gt;

&lt;h2&gt;
  
  
  The feature: a "working" line under every result
&lt;/h2&gt;

&lt;p&gt;Each calculator ends by calling one helper:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;work&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nf"&gt;set&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'ez-working'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;text&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c1"&gt;// Inside the Venmo calculator:&lt;/span&gt;
&lt;span class="nf"&gt;work&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;money&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;amt&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="s1"&gt;' × '&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;pct&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="s1"&gt;'% + '&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nf"&gt;money&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;fixed&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="s1"&gt;' = '&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="nf"&gt;money&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;fee&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="s1"&gt;' fee'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="c1"&gt;// → "$100.00 × 2.99% = $2.99 fee"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It's a tiny thing, but it changed how I wrote every calculator. If I couldn't print a clean one-line sum, the logic was probably too clever, and I simplified it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Bug 1: "How much should I charge to receive $100?"
&lt;/h2&gt;

&lt;p&gt;Fee calculators get asked this a lot. The textbook answer is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;amount to charge = (amount you want + fixed fee) ÷ (1 − percentage)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For Venmo's 2.99% that gives $103.0821, which I rounded &lt;strong&gt;up&lt;/strong&gt; to $103.09. But Venmo rounds its fee to the cent, so $103.08 already leaves exactly $100.00. I was telling people to overcharge by a cent.&lt;/p&gt;

&lt;p&gt;Worse, the formula falls apart for fees with a &lt;strong&gt;cap&lt;/strong&gt; or &lt;strong&gt;minimum&lt;/strong&gt;. Stripe's ACH fee is 0.8% capped at $5. To receive $1,000 you need $1,005, but the formula said $1,008.06.&lt;/p&gt;

&lt;p&gt;The fix was to stop solving it algebraically and search over whole cents instead:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="c1"&gt;// Smallest amount (in cents) whose fee still leaves `want`.&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;askFor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;want&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;pct&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;fixed&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;feeFn&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;lo&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;round&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;want&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="kd"&gt;let&lt;/span&gt; &lt;span class="n"&gt;hi&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;ceil&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;want&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;fixed&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;max&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;pct&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="mf"&gt;0.01&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;lo&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="n"&gt;hi&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="n"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nb"&gt;Math&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;floor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;lo&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;hi&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;2&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="nf"&gt;feeFn&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="n"&gt;want&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="mf"&gt;1e-9&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;hi&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;mid&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="n"&gt;lo&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;mid&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;lo&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;feeFn&lt;/code&gt; is the real fee function, with rounding, caps and minimums, so whatever rule a platform uses, the answer is exact. The formula only sets the upper bound for the search.&lt;/p&gt;

&lt;h2&gt;
  
  
  Bug 2: my test caught a wrong number in my own article
&lt;/h2&gt;

&lt;p&gt;Every tool page has a worked example in the text. I test each calculator by filling it with the example's numbers in headless Chrome (plain Chrome DevTools Protocol, no test framework) and comparing the output with what the page says.&lt;/p&gt;

&lt;p&gt;That's how I found the $103.09 bug: the calculator and the article disagreed. Testing against the prose turned out to be a cheap way to keep the explanations honest.&lt;/p&gt;

&lt;h2&gt;
  
  
  Bug 3: the security header that would have blocked my revenue
&lt;/h2&gt;

&lt;p&gt;My Content-Security-Policy only allowed scripts from my own domain and Cloudflare's analytics. When I added Google AdSense, the script would have been silently blocked in every browser. No error on my side, just no ads.&lt;/p&gt;

&lt;p&gt;I caught it by loading the page with the real headers and reading the console for CSP violations before deploying. Lesson: if you ship a strict CSP, re-test it every time you add a third-party script.&lt;/p&gt;

&lt;h2&gt;
  
  
  Fees change, so every fee page has a date
&lt;/h2&gt;

&lt;p&gt;Seven of the tools depend on other companies' fees. Blog posts about them disagree constantly, because they copy each other's old numbers. So every fee comes from the company's own page (Stripe's pricing page, Etsy's fee policy, Poshmark's fee policy and so on), and each tool page links its source and says when I checked it.&lt;/p&gt;

&lt;p&gt;Two I couldn't verify, I left out. Cash App's site is region-blocked where I live, and Shopify redirected me to a local pricing page without US card rates. I'd rather ship 20 correct tools than 22 with two guesses.&lt;/p&gt;

&lt;h2&gt;
  
  
  The SEO surprise
&lt;/h2&gt;

&lt;p&gt;Technically, everything went well:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Lighthouse 95–100 across the board&lt;/li&gt;
&lt;li&gt;Structured data (WebApplication, FAQ, Breadcrumbs) on every page&lt;/li&gt;
&lt;li&gt;A clean sitemap, canonical URLs and fast static pages&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Google indexed the pages within days and impressions started climbing. My first click came from "venmo fee calculator", one of the newest pages on the site.&lt;/p&gt;

&lt;p&gt;Then, about two weeks in, Google moved almost every tool page to &lt;strong&gt;"Crawled – currently not indexed"&lt;/strong&gt;. The pages weren't broken. Google's live test said "URL is available to Google, page can be indexed". It just decided not to keep them yet.&lt;/p&gt;

&lt;p&gt;What I learned:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Technical SEO gets you crawled, not indexed.&lt;/strong&gt; A new domain with no backlinks and 20 similar-looking pages published in three weeks looks like a calculator farm, even if every page is careful.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Check the boring settings.&lt;/strong&gt; Cloudflare's "Always Use HTTPS" was off, so every &lt;code&gt;http://&lt;/code&gt; URL returned a full page. Google found 24 duplicate copies of my site. It's one toggle, and now it's on.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Requesting indexing isn't a fix.&lt;/strong&gt; It gets pages recrawled faster, but Google re-checks them and says no again until it trusts the site.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Slow down publishing.&lt;/strong&gt; My next step is building real links and letting Google trust the pages I already have, not adding more.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I'll write a follow-up once pages come back (or don't).&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it, break it
&lt;/h2&gt;

&lt;p&gt;The site is &lt;a href="https://ezisolutions.online" rel="noopener noreferrer"&gt;ezisolutions.online&lt;/a&gt;. If you find a calculation that's wrong, or a fee that's out of date, I'd genuinely like to know. And if you've taken a new site through the "crawled, not indexed" phase, how long did it take for you?&lt;/p&gt;

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