An app to fix the page order of a double-sided PDF scan from a scanner without a duplex feature. It reorders the pages of a PDF from e.g. (1,3,5,4,2)
to the correct order (1,2,3,4,5)
.
Try out the app on pdf-duplex-scan.vercel.app with two example PDF files: Example 1 and Example 2.
- Drag-and-drop file selection
- Form validation
- Array reordering based on pattern
- User interface for dark and light color schemes
- JavaScript browser validation
- File format validation
Check out the app by running the project locally:
-
Clone this repo
git clone https://github.com/clemensheithecker/pdf-duplex-scan.git cd pdf-duplex-scan
-
Initialize the project's dependencies
npm install
-
Run the development server
npm run dev
The app uses several light-weight dependencies to run:
- Vite as a fast development server for vanilla JavaScript
- tailwindcss and its @tailwindcss/forms plugin for consistent styling directly in the HTML markup
- pdf-lib to create and modify PDF documents
- downloadjs to download files from JavaScript