A client-side web application for managing and rearranging PDF pages. Upload multiple PDFs, rearrange or delete pages, and export as a new combined PDF.
This application is hosted at: https://pdf-rearrange.netlify.app
- 📁 Select one or multiple PDF files
- 👁️ Preview all PDF pages
- 🔀 Drag and drop to rearrange pages
- 🗑️ Delete unwanted pages
- 💾 Export as a new combined PDF
- 🔒 Client-side processing (no files are uploaded to a server)
- React.js with Vite
- PDF.js for PDF rendering
- PDF-Lib for PDF manipulation
- Material UI for the interface
- React DnD for drag-and-drop functionality
-
Install dependencies:
npm install -
Start the development server:
npm run dev -
Build for production:
npm run build
This app can be easily deployed to various static hosting platforms:
# Install Netlify CLI if needed
npm install -g netlify-cli
# Build the app
npm run build
# Deploy to Netlify
netlify deploy --prod --dir=dist- Add the GitHub Pages workflow file to
.github/workflows/deploy.yml:
name: Deploy to GitHub Pages
on:
push:
branches: [ main ]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '18'
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: './dist'
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2- Enable GitHub Pages in your repository settings.
Most modern hosting platforms can automatically deploy this app by connecting to the GitHub repository.
- Click "Select PDFs" to choose one or more PDF files
- View the thumbnails of all pages
- Drag and drop to rearrange pages
- Click the trash icon to delete pages
- Click "Export PDF" to download the final document
All processing happens locally in your browser. Your PDF files are never uploaded to any server.
This application was created using Claude AI as part of an experiment in AI-assisted web development. The entire codebase was generated by Claude, with human guidance on requirements and adjustments.