meo-canvas
    Preparing search index...

    Function Root

    • Paints a scene and returns the canvas.

      import { Root, Row, Text } from 'meo-canvas'

      const canvas = await Root({
      width: 520,
      height: 180,
      backgroundColor: '#101014',
      children: Row({ padding: 24, children: Text('Ukasyah', { fontSize: 26 }) }),
      })

      await canvas.toFile('card.png')

      Parameters

      Returns Promise<Canvas>