This example shows how to build a PSPDFKit for Web web application with webpack.
This example uses the Standalone version of PSPDFKit for Web distributed as npm package.
- Node.js (with NPM)
- A valid PSPDFKit for Web license
git clone git@github.com:PSPDFKit/pspdfkit-web-example-webpack.git
cd pspdfkit-web-example-webpack
echo "place your license key here" > ./config/license-key
PSPDFKIT_NODE_KEY="place your node key here" npm install --save https://customers.pspdfkit.com/npm/${PSPDFKIT_NODE_KEY}/latest.tar.gz
npm install
npm start
The example app is built in the ./dist
folder and is now running on http://localhost:8080.
Upload a PDF either via the Select File
button at top-left or by dropping a PDF into the page.
We put a sample PDF document in the assets
folder of this project for you to try!
For further instructions please refer to our online guide available at https://pspdfkit.com/guides/web/current/standalone/adding-to-your-project#toc_install-with-npm
If you are using an evaluation license you can find the license key at https://pspdfkit.com/guides/web/current/standalone/integration/#toc_example-application
The webpack
configuration file is located at ./config/webpack.js.
To run the app in development mode run
npm run start:dev
Please ensure you signed our CLA so we can accept your contributions.