Skip to content
Sample to demonstrate integrating WebViewer into React
JavaScript HTML CSS
Branch: master
Clone or download
Latest commit 92edf49 Aug 21, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
public Create serve.json Aug 21, 2019
src Reference path and initialDoc from root Aug 8, 2019
.gitignore Added WebViewer.zip to gitignore Dec 28, 2018
CONTRIBUTING.md initial commit Nov 2, 2018
LICENSE initial commit Nov 2, 2018
README.md Update README.md Aug 21, 2019
package.json updated script Jun 6, 2019

README.md

WebViewer - React sample

WebViewer is a powerful JavaScript-based PDF Library that's part of the PDFTron PDF SDK. It provides a slick out-of-the-box responsive UI that interacts with the core library to view, annotate and manipulate PDFs that can be embedded into any web project.

WebViewer UI

This repo is specifically designed for any users interested in integrating WebViewer into React project. This project was generated with Create React App. See Create React App documentation for more information.

Initial setup

Before you begin, make sure your development environment includes Node.js.

Install

git clone https://github.com/PDFTron/webviewer-react-sample.git
cd webviewer-react-sample
npm install

Run

npm start

Build

Run npm run build to build the project. The build artifacts will be stored in the build/ directory. See the section about deployment for more information.

To test the build directory locally you can use serve or http-server. In case of serve, by default it strips the .html extension stripped from paths. We added serve.json configuration to disable cleanUrls option.

WebViewer APIs

See API documentation.

Contributing

See contributing.

License

See license.

You can’t perform that action at this time.