mirror of
https://github.com/apache/superset.git
synced 2024-09-19 12:09:42 -04:00
.. | ||
src | ||
test | ||
types | ||
package.json | ||
README.md | ||
tsconfig.json |
@superset-ui/plugin-filter-antd
This plugin provides native filter plugins based on AntD.
Usage
Configure key
, which can be any string
, and register the plugin. This key
will be used to lookup this chart throughout the app.
Below is an example of how to use the Select filter plugin.
import { AntdFilterSelectPlugin } from '@superset-ui/plugin-filter-antd';
new AntdFilterSelectPlugin()
.configure({ key: 'plugin-filter-select' })
.register();
Then use it via SuperChart
.
<SuperChart
chartType="plugin-filter-select"
width={600}
height={600}
formData={...}
queryData={{
data: {...},
// this hook gets called
hooks: { setExtraFormData: extraFormData => console.log(extraFormData) },
}}
/>