MCPcopy
hub / github.com/diegomura/react-pdf / create

Function create

packages/renderer/tests/renderComponent.js:15–22  ·  view source on GitHub ↗
(width, height)

Source from the content-addressed store, hash-verified

13 */
14const NodeCanvasFactory = {
15 create (width, height) {
16 const canvas = Canvas.createCanvas(width, height)
17 const context = canvas.getContext('2d')
18 return {
19 canvas,
20 context
21 }
22 },
23
24 reset (canvasAndContext, width, height) {
25 canvasAndContext.canvas.width = width

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected