<?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: RB</title>
    <description>The latest articles on DEV Community by RB (@rahul33859111).</description>
    <link>https://dev.to/rahul33859111</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%2F1407467%2F19cd066a-3cf8-42ce-aa0e-3a921086b3a9.png</url>
      <title>DEV Community: RB</title>
      <link>https://dev.to/rahul33859111</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/rahul33859111"/>
    <language>en</language>
    <item>
      <title>How I cut my AWS bill to $0 by moving my backend to the browser (WebAssembly)</title>
      <dc:creator>RB</dc:creator>
      <pubDate>Tue, 16 Jun 2026 06:52:34 +0000</pubDate>
      <link>https://dev.to/rahul33859111/how-i-cut-my-aws-bill-to-0-by-moving-my-backend-to-the-browser-webassembly-1nkb</link>
      <guid>https://dev.to/rahul33859111/how-i-cut-my-aws-bill-to-0-by-moving-my-backend-to-the-browser-webassembly-1nkb</guid>
      <description>&lt;p&gt;A few months ago, I was mapping out the architecture for a heavy file-processing application. The traditional SaaS playbook was obvious: &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;User uploads a heavy file.&lt;/li&gt;
&lt;li&gt;Store it in an AWS S3 bucket.&lt;/li&gt;
&lt;li&gt;Spin up an EC2 instance or AWS Lambda function to process it.&lt;/li&gt;
&lt;li&gt;Send the result back to the client.
But when I ran the numbers on processing thousands of 50MB files a day, the AWS bandwidth and compute costs were terrifying. Worse, uploading user files to my servers introduced massive privacy and GDPR liabilities.
I realized the traditional client-server model was the wrong approach. &lt;strong&gt;Modern browsers are incredibly powerful machines.&lt;/strong&gt; Why was I paying Amazon to process files when the user has an M1 Mac or a Snapdragon processor sitting right in front of them?
I decided to ditch the backend entirely and move the heavy lifting to the client using &lt;strong&gt;WebAssembly (WASM)&lt;/strong&gt;. Here is how I did it, and how you can apply this architecture to your own apps.
---
## The Paradigm Shift: Client-Side Compute
If you haven't played with WebAssembly yet, it fundamentally changes what you can build on the web. WASM allows you to compile languages like C, C++, and Rust into a binary format that runs directly inside the browser at near-native speeds.
Instead of sending &lt;em&gt;data&lt;/em&gt; to the server, you send the &lt;em&gt;server logic&lt;/em&gt; to the data.
### The Use Case: PDF Pro
To prove this architecture worked at scale, I built &lt;a href="https://www.pdfpro.co.in/" rel="noopener noreferrer"&gt;PDF Pro&lt;/a&gt;—a suite of tools that compress, merge, and edit massive PDF files.
Traditionally, PDF manipulation requires heavy server-side libraries like Ghostscript. But by bridging JavaScript with WASM-compiled PDF engines, I was able to invert the entire flow.
Here is the exact architecture I used to process files entirely in the user's RAM:
### 1. Intercepting the File Locally
Instead of wrapping the file input in a &lt;code&gt;&amp;lt;form action="/upload"&amp;gt;&lt;/code&gt;, we intercept the file locally using the File API.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;`document.getElementById('fileInput').addEventListener('change', async (event) =&amp;gt; {&lt;br&gt;
  const file = event.target.files[0];&lt;/p&gt;

&lt;p&gt;// Load the file into the browser's memory (RAM)&lt;br&gt;
  const arrayBuffer = await file.arrayBuffer();&lt;/p&gt;

&lt;p&gt;// Pass the buffer to the WASM engine instead of an API&lt;br&gt;
  processFileLocally(arrayBuffer);&lt;br&gt;
});`&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Processing in the Sandbox
&lt;/h3&gt;

&lt;p&gt;Once the file is an &lt;code&gt;ArrayBuffer&lt;/code&gt; in the browser's memory, we pass it to the WASM engine. &lt;br&gt;
For PDF Pro, the WASM engine tears down the binary structure of the document, strips out metadata, and uses the browser's native &lt;code&gt;&amp;lt;canvas&amp;gt;&lt;/code&gt; API to intelligently downsample heavy images. &lt;br&gt;
Because WASM runs at near-native speeds, a 20MB file that would normally take 15 seconds to upload to an AWS server is processed locally in about &lt;strong&gt;1.5 seconds&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Returning the Result
&lt;/h3&gt;

&lt;p&gt;Once the WASM engine finishes processing, it generates a new binary &lt;code&gt;Blob&lt;/code&gt;. We use &lt;code&gt;URL.createObjectURL()&lt;/code&gt; to instantly trigger a download back to the user's hard drive. &lt;br&gt;
&lt;code&gt;&lt;/code&gt; `javascript&lt;br&gt;
function triggerLocalDownload(processedBytes, filename) {&lt;br&gt;
  const blob = new Blob([processedBytes], { type: 'application/pdf' });&lt;br&gt;
  const url = URL.createObjectURL(blob);&lt;/p&gt;

&lt;p&gt;const a = document.createElement('a');&lt;br&gt;
  a.href = url;&lt;br&gt;
  a.download = &lt;code&gt;optimized_${filename}&lt;/code&gt;;&lt;br&gt;
  a.click();&lt;/p&gt;

&lt;p&gt;URL.revokeObjectURL(url); // Clean up memory&lt;br&gt;
}&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;code&gt; &lt;/code&gt; `
&lt;/h2&gt;

&lt;h2&gt;
  
  
  The 3 Massive Benefits of this Architecture
&lt;/h2&gt;

&lt;p&gt;If you are building a tool that handles images, video, audio, or document processing, you should strongly consider moving it to the client.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Infinite Scaling for $0:&lt;/strong&gt; Because the compute happens on the user's device, my server costs are identical whether I have 10 users or 100,000 users. I only pay for static frontend hosting (Vercel/Netlify).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Zero Privacy Liability:&lt;/strong&gt; I don't have to worry about hackers breaching my S3 buckets or GDPR compliance, because &lt;em&gt;I never receive the user's data.&lt;/em&gt; It never leaves their laptop.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Instant UX:&lt;/strong&gt; There are no loading bars while a user waits for a 50MB file to upload over a slow 3G connection. The processing starts instantly.
## See it in action
If you want to see how fast this architecture actually feels in production, you can test the live app here: &lt;strong&gt;&lt;a href="https://www.pdfpro.co.in/tools/compress-pdf" rel="noopener noreferrer"&gt;PDF Pro Local Compressor&lt;/a&gt;&lt;/strong&gt;. You can literally load the page, turn off your Wi-Fi, and it will still process your files flawlessly.
I also open-sourced the underlying WASM architecture on GitHub if you want to poke around the code: &lt;strong&gt;&lt;a href="https://github.com/rbanerjee78/wasm-pdf-compressor" rel="noopener noreferrer"&gt;GitHub Repo&lt;/a&gt;&lt;/strong&gt;.
Have you started using WebAssembly in your side projects yet? I'd love to hear what use-cases you think this client-side architecture fits best!&lt;/li&gt;
&lt;/ol&gt;

</description>
      <category>webdev</category>
      <category>webassembly</category>
      <category>architecture</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Why We Stopped Sending Sensitive Documents to the Cloud (and Built a Local-First AI Analyzer Instead)</title>
      <dc:creator>RB</dc:creator>
      <pubDate>Fri, 12 Jun 2026 12:05:27 +0000</pubDate>
      <link>https://dev.to/rahul33859111/why-we-stopped-sending-sensitive-documents-to-the-cloud-and-built-a-local-first-ai-analyzer-jg5</link>
      <guid>https://dev.to/rahul33859111/why-we-stopped-sending-sensitive-documents-to-the-cloud-and-built-a-local-first-ai-analyzer-jg5</guid>
      <description>&lt;p&gt;If you are a startup founder, you know the drill. You spend weeks agonizing over financial projections, customer acquisition costs, and intellectual property details to build the perfect Pitch Deck.&lt;br&gt;
If you run an agency, you know the pain of reading a 50-page Enterprise RFP (Request for Proposal), terrified that you might miss a single ISO compliance requirement that instantly disqualifies your bid.&lt;br&gt;
Naturally, in 2024, the first instinct is to upload these massive PDFs to ChatGPT or Claude and ask for a summary.&lt;br&gt;
&lt;strong&gt;Stop doing this.&lt;/strong&gt;&lt;br&gt;
When you upload your unreleased pitch deck, your NDA-protected contracts, or your dense insurance policies to public AI chat interfaces, you are feeding your highly sensitive data into remote cloud servers. &lt;br&gt;
We realized this was a massive security flaw for B2B users. So, we decided to build a completely private alternative.&lt;/p&gt;

&lt;h2&gt;
  
  
  Here is how we built a 100% private, local-first AI Document Intelligence platform using WebAssembly, and why you should care.
&lt;/h2&gt;

&lt;h2&gt;
  
  
  The Privacy Problem with Cloud AI
&lt;/h2&gt;

&lt;p&gt;Most "AI PDF Summarizers" on the market work like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;You drag and drop your PDF.&lt;/li&gt;
&lt;li&gt;The file is uploaded to an AWS S3 bucket.&lt;/li&gt;
&lt;li&gt;A backend server parses the text.&lt;/li&gt;
&lt;li&gt;The text is sent to an LLM provider.&lt;/li&gt;
&lt;li&gt;The result is returned to you.
The problem is step 2. Your file is now sitting on a server you don't control. For a high-stakes Enterprise RFP under strict NDA, or a Pitch Deck with unannounced IP, this is a fatal breach of data security protocols.
## Enter WebAssembly (Wasm)
We wanted the power of AI analysis, but the privacy of a desktop application. The solution was &lt;strong&gt;WebAssembly&lt;/strong&gt;.
Instead of uploading the PDF to our servers, we process the file entirely within the user's browser. 
Here is the architecture we landed on for &lt;a href="https://www.pdfpro.co.in/" rel="noopener noreferrer"&gt;PDF Pro AI&lt;/a&gt;:&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Client-Side Parsing:&lt;/strong&gt; We use a WebAssembly build of Mozilla's &lt;code&gt;pdf.js&lt;/code&gt; (&lt;code&gt;pdf.worker.min.mjs&lt;/code&gt;). When a user drops a file, the Wasm engine spins up directly in their Chrome/Safari browser.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Local Extraction:&lt;/strong&gt; The text extraction happens locally on the user's RAM. The &lt;code&gt;.pdf&lt;/code&gt; file itself &lt;strong&gt;never&lt;/strong&gt; leaves their device via a network request.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Targeted AI Routing:&lt;/strong&gt; Once the text is extracted locally, only the raw text strings are sent via a secure, transient API call to the LLM (bypassing any file storage mechanisms). &lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Zero-Retention:&lt;/strong&gt; Because we never receive the file, there is nothing to store, nothing to leak, and nothing to train future models on.
## The Use Cases We Built It For
Once we nailed the local-first extraction pipeline, we realized we could fine-tune the AI prompts for highly specific, high-risk B2B documents. 
We just launched two specific tools built on this architecture:
### 1. The RFP &amp;amp; Pitch Deck Analyzer
We wrote a dynamic prompt architecture that changes based on the document type:&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;For Pitch Decks:&lt;/strong&gt; The AI is instructed to act as a harsh Venture Capitalist. It completely ignores marketing fluff and actively hunts for missing financial metrics (CAC, LTV, Burn Rate) to give you realistic feedback before you pitch.&lt;/li&gt;
&lt;li&gt;  &lt;strong&gt;For Enterprise RFPs:&lt;/strong&gt; The AI acts as a Procurement Officer. It ignores the company history and strictly extracts hard compliance requirements, ISO certifications, and deadlines, ensuring you don't waste 40 hours writing a bid you are legally disqualified from winning.
&lt;a href="https://www.pdfpro.co.in/tools/rfp-pitch-deck-analyzer" rel="noopener noreferrer"&gt;Try the RFP &amp;amp; Pitch Deck Analyzer here (Free Beta)&lt;/a&gt;
### 2. The Insurance Policy Analyzer
Insurance companies make money by burying exclusions in 60-page PDFs. We trained the AI to act as a skeptical claims adjuster. It scans Health, Life, and Auto policies specifically to extract deductibles and summarize the "Hidden Exclusions" (like pre-existing condition loopholes) in plain English.
&lt;a href="https://www.pdfpro.co.in/tools/insurance-policy-analyzer" rel="noopener noreferrer"&gt;Try the Insurance Policy Analyzer here&lt;/a&gt;
## The Future is Local-First
As AI continues to integrate into professional workflows, the divide between "convenient" tools and "secure" tools will grow. By leveraging WebAssembly for client-side processing, we can give users the best of both worlds: Enterprise-grade AI analysis, without sacrificing document privacy.
If you are a founder dealing with pitch decks, or an agency dealing with NDAs and RFPs, try processing them locally first. Your IP will thank you.
---
&lt;em&gt;Built with Next.js, WebAssembly, and Gemini. Check out the full suite of private document intelligence tools at &lt;a href="https://www.pdfpro.co.in/" rel="noopener noreferrer"&gt;PDF Pro&lt;/a&gt;.&lt;/em&gt;
&lt;/li&gt;
&lt;/ol&gt;

</description>
      <category>ai</category>
      <category>javascript</category>
      <category>security</category>
      <category>showdev</category>
    </item>
    <item>
      <title>How We Built a Zero-Upload PDF Editor in WebAssembly to Beat the $108/yr Paywalls</title>
      <dc:creator>RB</dc:creator>
      <pubDate>Thu, 11 Jun 2026 09:56:26 +0000</pubDate>
      <link>https://dev.to/rahul33859111/how-we-built-a-zero-upload-pdf-editor-in-webassembly-to-beat-the-108yr-paywalls-4col</link>
      <guid>https://dev.to/rahul33859111/how-we-built-a-zero-upload-pdf-editor-in-webassembly-to-beat-the-108yr-paywalls-4col</guid>
      <description>&lt;p&gt;For years, whenever I needed to merge two PDFs or compress a file to upload to a government portal, I would Google "compress PDF", click the first result, and inevitably hit a paywall.&lt;br&gt;
"You have reached your 2 free files per day limit."&lt;br&gt;
Worse, I was uploading sensitive documents—tax returns, medical records, and NDAs—to random servers in God-knows-where just to strip out some heavy images.&lt;br&gt;
I decided to build an alternative. I wanted it to be 100% free, have absolutely no daily limits, and most importantly: &lt;strong&gt;zero server uploads&lt;/strong&gt;.&lt;br&gt;
Here is how we built &lt;a href="https://www.pdfpro.co.in" rel="noopener noreferrer"&gt;PDF Pro&lt;/a&gt; using Next.js and WebAssembly to process PDFs entirely natively inside the user's browser.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Architecture: Why WebAssembly?
&lt;/h2&gt;

&lt;p&gt;Traditional PDF tools (like Smallpdf or iLovePDF) use a monolithic server architecture. You upload your file to their AWS bucket, their backend runs a Python or C++ script (usually using Ghostscript or a proprietary library) to manipulate the PDF, and then you download the processed file.&lt;br&gt;
This architecture is expensive (high bandwidth and compute costs) and creates a massive privacy liability.&lt;br&gt;
By compiling a C++ PDF manipulation library down to &lt;strong&gt;WebAssembly (WASM)&lt;/strong&gt;, we inverted the architecture. &lt;/p&gt;

&lt;h3&gt;
  
  
  1. The Build Process
&lt;/h3&gt;

&lt;p&gt;We took &lt;code&gt;pdf-lib&lt;/code&gt; and custom C++ compression algorithms and compiled them to a lightweight &lt;code&gt;.wasm&lt;/code&gt; binary. When a user visits &lt;a href="https://www.pdfpro.co.in/en/tools/compress-pdf" rel="noopener noreferrer"&gt;PDF Pro Compress&lt;/a&gt;, their browser downloads the ~2MB WASM file once and caches it.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Client-Side Processing
&lt;/h3&gt;

&lt;p&gt;When you drag and drop a 50MB PDF into the UI, it never hits our server. Instead, the browser's JavaScript engine passes a Pointer to the file data directly into the WebAssembly memory buffer. The WASM module executes native C++ speeds directly on your local CPU to compress or merge the document.&lt;/p&gt;

&lt;h2&gt;
  
  
  Performance Benchmarks
&lt;/h2&gt;

&lt;p&gt;Because there is zero upload and zero download time, the performance metrics are staggering:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;10MB PDF Compression (Cloud):&lt;/strong&gt; ~15 seconds (Upload) + 4 seconds (Process) + 5 seconds (Download) = &lt;strong&gt;24 seconds&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;10MB PDF Compression (PDF Pro WASM):&lt;/strong&gt; 0 seconds (Upload) + 1.2 seconds (Process) + 0 seconds (Download) = &lt;strong&gt;1.2 seconds&lt;/strong&gt;.
It's nearly 20x faster because the speed of light (internet latency) is no longer a factor.
## The SEO Challenge: Competing with Giants
Building a better tool is only half the battle. The incumbents have millions of backlinks and dominate the root keyword "compress pdf". 
To compete, we employed a highly aggressive Programmatic SEO strategy. Instead of fighting for the root keyword, we programmatically generated hundreds of hyper-specific landing pages tailored to the exact problem the user is trying to solve.
Instead of searching "compress PDF", users search for &lt;a href="https://www.pdfpro.co.in/en/tools/compress-pdf/1mb-passport-seva" rel="noopener noreferrer"&gt;Compress PDF to 1MB for Passport Seva&lt;/a&gt; or &lt;a href="https://www.pdfpro.co.in/en/tools/merge-pdf/bank-statements" rel="noopener noreferrer"&gt;Merge Bank Statements securely&lt;/a&gt;. 
Because our landing pages exactly match the search intent, Google ranks them highly, completely bypassing the massive marketing budgets of the incumbents.
## Try it out (And check the Network Tab!)
If you want to see the architecture in action, try merging a few files at &lt;a href="https://www.pdfpro.co.in/en/tools/merge-pdf" rel="noopener noreferrer"&gt;PDF Pro&lt;/a&gt;. 
Open your Chrome Developer Tools, head to the Network tab, and hit merge. You will see absolutely zero network requests firing. Your files never leave your machine.
It's 100% free, unlimited, and private. Let me know what you think of the WebAssembly implementation in the comments!&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>nextjs</category>
      <category>privacy</category>
      <category>showdev</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Stop sending user PDFs to random cloud APIs (how to do it locally) published</title>
      <dc:creator>RB</dc:creator>
      <pubDate>Mon, 08 Jun 2026 11:59:48 +0000</pubDate>
      <link>https://dev.to/rahul33859111/stop-sending-user-pdfs-to-random-cloud-apis-how-to-do-it-locally-published-7ha</link>
      <guid>https://dev.to/rahul33859111/stop-sending-user-pdfs-to-random-cloud-apis-how-to-do-it-locally-published-7ha</guid>
      <description>&lt;p&gt;I recently had to build a feature where users could merge a bunch of invoices and scan them for specific keywords.&lt;/p&gt;

&lt;p&gt;My first instinct was to do what I always do: grab an API key from Adobe or some generic PDF service, send the file to their server, wait 4 seconds, and get the merged file back.&lt;/p&gt;

&lt;p&gt;But looking at the actual data—these were medical bills and tax documents—I realized how insane that workflow is. Why are we conditioning users to upload highly sensitive documents to random AWS buckets just to stitch two pages together? It’s a massive privacy risk, and honestly, the API latency is annoying.&lt;/p&gt;

&lt;p&gt;I spent the weekend ripping out the backend API and forcing everything to run client-side. Here is what I learned.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;You don't need a backend for PDF manipulation anymore&lt;/strong&gt;&lt;br&gt;
If you haven't checked out pdf-lib recently, you should. It compiles down to WebAssembly, which means your browser can chew through binary PDF manipulation just as fast as a Node backend.&lt;/p&gt;

&lt;p&gt;I threw together a simple utility function. No Express server, no AWS S3 buckets, no waiting for a network request to finish.&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="k"&gt;import&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nx"&gt;PDFDocument&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt; &lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;pdf-lib&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="c1"&gt;// Runs entirely in the browser&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;mergeLocally&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;file1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;file2&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="nx"&gt;pdf1&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;PDFDocument&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;load&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;file1&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;arrayBuffer&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;pdf2&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;PDFDocument&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;load&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;file2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;arrayBuffer&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;

  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;merged&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;PDFDocument&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;create&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

  &lt;span class="c1"&gt;// Copy and append pages&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;p1&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;merged&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;copyPages&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pdf1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;pdf1&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getPageIndices&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;p2&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;merged&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;copyPages&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;pdf2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;pdf2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getPageIndices&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;

  &lt;span class="nx"&gt;p1&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;forEach&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;page&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;merged&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;addPage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;page&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
  &lt;span class="nx"&gt;p2&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;forEach&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;page&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;merged&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;addPage&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;page&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;

  &lt;span class="c1"&gt;// spit out a blob for the user to download&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;bytes&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="nx"&gt;merged&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;save&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Blob&lt;/span&gt;&lt;span class="p"&gt;([&lt;/span&gt;&lt;span class="nx"&gt;bytes&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;application/pdf&lt;/span&gt;&lt;span class="dl"&gt;'&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;That’s literally it.&lt;/p&gt;

&lt;p&gt;I got a bit obsessed with the "Zero Upload" architecture. Once I realized how snappy it felt to bypass the network tab entirely, I ended up building an entire UI around it.&lt;/p&gt;

&lt;p&gt;I put it live at &lt;a href="https://www.pdfpro.co.in" rel="noopener noreferrer"&gt;PDF Pro AI&lt;/a&gt; just to see how far I could push browser-based processing. I even got a Contract Analyzer working that extracts text locally via WASM before doing any AI checks, so the physical PDF never touches my database.&lt;/p&gt;

&lt;p&gt;If you're building SaaS products that handle NDAs, tax forms, or medical records, give client-side parsing a shot. It completely eliminates your server costs for file processing, and more importantly, you don't have to worry about accidentally leaking your users' files.&lt;/p&gt;

&lt;p&gt;Has anyone else completely ditched backend PDF rendering, or is there a use-case I'm missing where server-side is still strictly better?&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>react</category>
      <category>privacy</category>
    </item>
    <item>
      <title>Why I Built My Free PDF Editor with WebAssembly (Zero Server Uploads)</title>
      <dc:creator>RB</dc:creator>
      <pubDate>Fri, 22 May 2026 13:13:08 +0000</pubDate>
      <link>https://dev.to/rahul33859111/why-i-built-my-free-pdf-editor-with-webassembly-zero-server-uploads-1ibe</link>
      <guid>https://dev.to/rahul33859111/why-i-built-my-free-pdf-editor-with-webassembly-zero-server-uploads-1ibe</guid>
      <description>&lt;p&gt;If you’ve ever tried to compress a bank statement or merge sensitive PDF documents online, you’ve probably noticed the process: you upload the file, wait for a progress bar, and then download the result. &lt;/p&gt;

&lt;p&gt;But what happens to that file on the server?&lt;br&gt;
Most free PDF tools (like ILovePDF or Smallpdf) upload your highly sensitive documents to remote servers to process them. This is a massive privacy risk for documents containing PAN cards, Aadhaar numbers, and financial statements. &lt;/p&gt;

&lt;p&gt;To solve this, I built &lt;strong&gt;&lt;a href="https://www.pdfpro.co.in" rel="noopener noreferrer"&gt;PDF Pro&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why WebAssembly (WASM)?
&lt;/h3&gt;

&lt;p&gt;Instead of sending your files to a server, I used WebAssembly to compile a heavy C++ PDF processing library directly into Javascript. &lt;/p&gt;

&lt;p&gt;This means the entire PDF engine runs &lt;strong&gt;locally inside your browser&lt;/strong&gt;. &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Zero Uploads:&lt;/strong&gt; Your file literally never leaves your computer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Instant Speed:&lt;/strong&gt; Because there is no network latency, compressing a 10MB file happens in milliseconds instead of minutes.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;100% Free:&lt;/strong&gt; No servers means no cloud computing costs. I can afford to offer this tool completely free with zero daily limits.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Built for the Indian Web
&lt;/h3&gt;

&lt;p&gt;I specifically optimized PDF Pro to target government portal limits. The Staff Selection Commission (SSC) and UPSC require documents to be strictly under 200KB. &lt;/p&gt;

&lt;p&gt;Instead of arbitrarily dropping quality and making your scanned certificates blurry, the WebAssembly engine strips embedded fonts and intelligently down-samples resolution to exactly 150 DPI—maintaining crystal clear vector text while satisfying the portal sizes.&lt;/p&gt;

&lt;p&gt;If you are a developer, CA, or student tired of uploading your personal data to random websites, try it out: &lt;strong&gt;&lt;a href="https://www.pdfpro.co.in" rel="noopener noreferrer"&gt;PDF Pro - Free &amp;amp; Private PDF Tools&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>webassembly</category>
      <category>privacy</category>
      <category>showdev</category>
    </item>
    <item>
      <title>ShowDev: I built a 100% local, zero-upload PDF editor using WebAssembly</title>
      <dc:creator>RB</dc:creator>
      <pubDate>Thu, 21 May 2026 13:36:08 +0000</pubDate>
      <link>https://dev.to/rahul33859111/showdev-i-built-a-100-local-zero-upload-pdf-editor-using-webassembly-19o5</link>
      <guid>https://dev.to/rahul33859111/showdev-i-built-a-100-local-zero-upload-pdf-editor-using-webassembly-19o5</guid>
      <description>&lt;p&gt;Why I Built a Privacy-First PDF Tool for India's Government Portals (And the Tech Behind It)&lt;br&gt;
Updated&lt;br&gt;
May 20, 2026&lt;br&gt;
•&lt;br&gt;
5 min read&lt;br&gt;
RahulBanerjee&lt;br&gt;
RahulBanerjee&lt;br&gt;
Part of series&lt;br&gt;
Building in Public — PDF Pro&lt;br&gt;
Every Indian who has applied for a government job, filed an ITR, or renewed their passport knows the frustration I'm about to describe.&lt;/p&gt;

&lt;p&gt;You have spent hours gathering your documents — Aadhaar card, PAN card, marksheets, photographs. You open the portal. You upload your carefully scanned PDF. And then you see it:&lt;/p&gt;

&lt;p&gt;❌ "File size exceeds the maximum limit of 200KB. Please upload a smaller file."&lt;/p&gt;

&lt;p&gt;Your file is 2.1MB. You try again. 1.8MB. Still rejected. You are now frantically Googling "how to compress PDF online free" at 11:45 PM, the night before the application deadline.&lt;/p&gt;

&lt;p&gt;Every tool you find has the same catch: upload your document to our servers first.&lt;/p&gt;

&lt;p&gt;That is exactly the problem I set out to solve.&lt;/p&gt;

&lt;p&gt;The Privacy Problem Nobody Talks About Think about what you are uploading when you use a typical online PDF compressor:&lt;/p&gt;

&lt;p&gt;Your Aadhaar card (your national identity number) Your PAN card (your tax identity) Your bank statements (your complete financial history) Your ITR filings (income, assets, liabilities) These files are being sent to servers in the US, Europe, or wherever the company is hosted. You have no idea what happens to them after processing. Are they stored? For how long? Are they used to train AI models? Are they sold?&lt;/p&gt;

&lt;p&gt;Most privacy policies of these tools are vague at best and alarming at worst.&lt;/p&gt;

&lt;p&gt;When I dug into this problem, I realized the solution already existed in the browser. We just weren't using it.&lt;/p&gt;

&lt;p&gt;The Solution: WebAssembly Changes Everything Modern browsers ship with a technology called WebAssembly (Wasm) — a binary instruction format that lets you run near-native speed code directly inside the browser sandbox.&lt;/p&gt;

&lt;p&gt;Libraries like pdf-lib and Ghostscript compiled to Wasm mean you can run a full PDF compression engine entirely inside the user's browser tab.&lt;/p&gt;

&lt;p&gt;Here is what this means practically:&lt;/p&gt;

&lt;p&gt;Traditional Cloud Tool: User → Upload file to server → Server compresses → Download result ↑ Your private document lives on their infrastructure PDF Pro (Wasm-based): User → File loads in browser memory → Browser compresses locally → Download result ↑ Your document never leaves your computer The file never touches a remote server. Not even for a millisecond.&lt;/p&gt;

&lt;p&gt;Building PDF Pro I built PDF Pro (&lt;a href="https://pdfpro.co.in" rel="noopener noreferrer"&gt;https://pdfpro.co.in&lt;/a&gt;) as a Next.js application with a Wasm core. Here is the architecture in plain terms:&lt;/p&gt;

&lt;p&gt;Frontend: Next.js 16 (App Router) hosted on Vercel PDF Engine: WebAssembly-compiled compression libraries running client-side Analytics: Google Analytics for aggregate visitor counting only — no PII Backend: None. There is no backend that touches your files.&lt;/p&gt;

&lt;p&gt;The stack is intentionally minimal. The less infrastructure you have, the less can go wrong from a privacy standpoint.&lt;/p&gt;

&lt;p&gt;The Compression Challenge Government portals in India have wildly different file size requirements:&lt;/p&gt;

&lt;p&gt;Portal Limit UPSC IAS Application 200KB SSC CGL 200KB IBPS PO 500KB Passport Seva 1MB ITR Filing 1MB Visa Application 1MB Building a single tool that handles all these targets while preserving document readability was the core engineering challenge. Too aggressive on compression and your Aadhaar number becomes unreadable. Too gentle and the portal rejects the file.&lt;/p&gt;

&lt;p&gt;The solution was letting the user control the compression level explicitly, with a real-time preview of the output file size before they download.&lt;/p&gt;

&lt;p&gt;What I Learned Building This&lt;/p&gt;

&lt;p&gt;Indian users are underserved by Western productivity tools Most global PDF tools are built for English-speaking Western users filing corporate documents. The specific pain point of compressing identity documents for strict-size government portals is a uniquely Indian problem that nobody was solving well.&lt;/p&gt;

&lt;p&gt;Privacy is a feature, not a checkbox When I started describing PDF Pro as "your files never leave your browser," the response from users was immediate and emotional. People care about this. They had just never had a tool that made it the central promise.&lt;/p&gt;

&lt;p&gt;WebAssembly is criminally underused in productivity tools The performance of Wasm-compiled PDF libraries surprised even me. Compression that would take a server round-trip (upload → process → download) now completes in under 3 seconds on a mid-range phone, entirely offline, with no latency.&lt;/p&gt;

&lt;p&gt;The Bigger Picture We talk a lot in the developer community about building products for global audiences. But there are 1.4 billion people in India navigating government digital infrastructure that was not designed with them in mind.&lt;/p&gt;

&lt;p&gt;If you know WebAssembly, you have a genuine superpower to fix these problems — tools that work offline, respect privacy by design, and don't require a subscription or an account.&lt;/p&gt;

&lt;p&gt;PDF Pro is proudly built in India. Not as a marketing line, but as a genuine statement of intent about who this tool is for.&lt;/p&gt;

&lt;p&gt;Try It The tool is completely free with no account required:&lt;/p&gt;

&lt;p&gt;👉 &lt;a href="https://pdfpro.co.in" rel="noopener noreferrer"&gt;https://pdfpro.co.in&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you are a developer curious about the Wasm implementation, feel free to reach out at &lt;a href="mailto:rahulorama@gmail.com"&gt;rahulorama@gmail.com&lt;/a&gt; . I am happy to discuss the technical architecture in more detail.&lt;/p&gt;

&lt;p&gt;And if you are an Indian developer building tools for Indian problems — I would love to connect. This space needs more of us.&lt;/p&gt;

&lt;p&gt;Rahul Banerjee is an independent developer based in India. He builds privacy-first productivity tools using modern web technologies.&lt;/p&gt;

&lt;h1&gt;
  
  
  webdev
&lt;/h1&gt;

&lt;h1&gt;
  
  
  javascript
&lt;/h1&gt;

&lt;h1&gt;
  
  
  webassembly
&lt;/h1&gt;

</description>
      <category>webdev</category>
      <category>javascript</category>
      <category>productivity</category>
      <category>showdev</category>
    </item>
  </channel>
</rss>
