Skip to content

Provides methods to open print preview for a specific component

License

Notifications You must be signed in to change notification settings

vladimirmoushkov/react-print-tool

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-print-tool

Provides methods to open print preview for a specific component

Installation

npm install react-print-tool

Usage

Import the react tool object and use one of the provided methods

Example

 import { PrintTool } from "react-print-tool"

//use your own react component
 PrintTool.printFromReactComponent(<TheBestReactComponent prop={data} /> )

 // use html in a string
 PrintTool.printFromString("<div>Hello world</div>" )

// use selector to print an existing html element
 PrintTool.printExistingElement("div.elementClass #elementID")

About

Provides methods to open print preview for a specific component

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 100.0%