Crop PDFs in browser or portable app

Wuqiong Zhao's pdfcrop Web App is sublimely fit to purpose. Tried wrangling a Tauri-based portable Windows app out of it with Claude 4.6 Opus, Gemini 3.1 Pro, and GPT 5.4 over several hours with little to show for it.

Dear friend and AI whisperer Josh adroitly conjured up a wonderful solution using Copilot & GPT-5.4-high in a twinkling, even fixing crop-box handle resizing along the way:

Successfully tested the following build steps in Windows 11 24H2 ARM64, macOS 26.4.1 Tahoe, and Ubuntu Linux 22.04:

1. Install prerequisites

Windows

macOS

macOS offers native PDF cropping in Preview.

Linux

2. Configure Rust

rustup target add wasm32-unknown-unknown
cargo install tauri-cli --locked

3. Clone and enter the repo

git clone https://github.com/citricguy/pdfcrop.github.io-tauri/
cd pdfcrop.github.io-tauri\pdfcrop\examples\pdfcrop.github.io

4. Install JS dependencies

npm install

5. Build WASM package

wasm-pack build --target web --release --out-dir pkg

6. Compile the app

npm run desktop:build

In Windows, find pdfcrop-desktop.exe (~5MB) in src-tauri\target\release\. To build for x64 & x86 under ARM64:

rustup target add x86_64-pc-windows-msvc
cargo tauri build --target x86_64-pc-windows-msvc
rustup target add i686-pc-windows-msvc
cargo tauri build --target i686-pc-windows-msvc

Related

❧ 2026-04-10