0.1.6 • Published 4 months ago

@antv/gpt-vis-ssr v0.1.6

Weekly downloads
-
License
MIT
Repository
github
Last release
4 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

4 months ago

0.1.5

5 months ago

0.1.4

5 months ago

0.1.3

5 months ago

0.1.2

5 months ago

0.1.1

5 months ago

0.1.0

6 months ago