html2canvas/docs/getting-started.md
2017-12-07 23:50:30 +08:00

528 B

title
Getting Started

Installing

You can install html2canvas through npm or download a built release.

npm

npm install html2canvas
import html2canvas from 'html2canvas';

Usage

To render an element with html2canvas with some (optional) options, simply call html2canvas(element, options);

html2canvas(document.body).then(function(canvas) {
    document.body.appendChild(canvas);
});