superset/superset-frontend/plugins/plugin-chart-handlebars
Đỗ Trọng Hải 0ca42a8e4d
chore: remove React 16.4's obsolete React imports (#28571)
Signed-off-by: hainenber <dotronghai96@gmail.com>
2024-06-05 08:13:24 -03:00
..
src chore: remove React 16.4's obsolete React imports (#28571) 2024-06-05 08:13:24 -03:00
test chore(frontend): Spelling (#19676) 2023-02-02 11:23:11 -07:00
types chore: adding missing examples in the gallery for several chart types (#22597) 2023-01-05 11:43:32 +02:00
README.md docs: replace broken david badges with libraries.io (#27903) 2024-04-04 23:00:23 -06:00
package.json chore(deps-dev): update @types/lodash requirement from ^4.17.0 to ^4.17.4 in /superset-frontend/plugins/plugin-chart-handlebars (#28822) 2024-06-03 09:23:07 -07:00
tsconfig.json feat: Adds plugin-chart-handlebars (#17903) 2022-04-26 14:34:28 +03:00

README.md

@superset-ui/plugin-chart-handlebars

Version Libraries.io

This plugin renders the data using a handlebars template.

Usage

Configure key, which can be any string, and register the plugin. This key will be used to lookup this chart throughout the app.

import HandlebarsChartPlugin from '@superset-ui/plugin-chart-handlebars';

new HandlebarsChartPlugin().configure({ key: 'handlebars' }).register();

Then use it via SuperChart. See storybook for more details.

<SuperChart
  chartType="handlebars"
  width={600}
  height={600}
  formData={...}
  queriesData={[{
    data: {...},
  }]}
/>

File structure generated

├── package.json
├── README.md
├── tsconfig.json
├── src
│   ├── Handlebars.tsx
│   ├── images
│   │   └── thumbnail.png
│   ├── index.ts
│   ├── plugin
│   │   ├── buildQuery.ts
│   │   ├── controlPanel.ts
│   │   ├── index.ts
│   │   └── transformProps.ts
│   └── types.ts
├── test
│   └── index.test.ts
└── types
    └── external.d.ts