Package Exports
- bv-react-data-report
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (bv-react-data-report) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
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 startGeneral 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 jspdfOr yarn
yarn add bv-react-data-report html2canvas i18n-react jspdf