0.1.6 • Published 10 months ago

@antv/gpt-vis-ssr v0.1.6

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

gpt-vis-ssr

Render GPT-Vis in Server-Side with NodeJS.

Installation

npm install --save @antv/gpt-vis-ssr

Usage

import { render } from '@antv/gpt-vis-ssr';

const options = {
  type: 'line',
  data: [
    { time: 2018, value: 91.9 },
    { time: 2019, value: 99.1 },
    { time: 2020, value: 101.6 },
    { time: 2021, value: 114.4 },
    { time: 2022, value: 121 },
  ],
};

const vis = await render(options);

const buffer = vis.toBuffer();

API

render(options: Options)

Render spec into image buffer in NodeJS.

License

MIT

0.1.6

10 months ago

0.1.5

10 months ago

0.1.4

10 months ago

0.1.3

10 months ago

0.1.2

10 months ago

0.1.1

11 months ago

0.1.0

11 months ago