bv-react-data-report
v2.0.1
Published
ReactJS component to preview data and export it as PDF file.
Downloads
9
Maintainers
Readme
bv-react-data-report
This is a ReactJS Component that generate a preview of data to be exported as PDF file.
The user will be able to choose the items per page, the page format (portrait / landscape) and the page size (a4 / letter / legal).
The package expose the libs to be overwritten if you want to customize any behavior.
Dependencies:
Example:
To run the test:
- Clone the repository
- Execute in console:
yarn
yarn start
General Usage
import Report from 'bv-react-data-report';
import 'bv-react-data-report/dist/index.css';
Then, in the render method we can just call it like:
<Report data={[{ id: 1, value: 'Some value' }, { id: 2, value: 'Some other value' }]}/>
Where data is an array of objects as you can see in this example file.
Installation
Install this component is easy, just use npm as:
npm install bv-react-data-report html2canvas i18n-react jspdf
Or yarn
yarn add bv-react-data-report html2canvas i18n-react jspdf