Skip to content

custom

Custom data processing logic that allows users to define their own operation methods.

Getting Started

const data = [
  { a: 1, b: 2, c: 3 },
  { a: 4, b: 5, c: 6 },
];

chart.options({
  type: 'view',
  data: {
    type: 'inline',
    value: data,
    transform: [
      {
        type: 'custom',
        callback: (data) => data.map((d) => ({ ...d, sum: d.a + d.b + d.c })),
      },
    ],
  },
});

Options

Property Description Type Default
callback Custom processing function (data: any[]) => any[]
© Copyright 2026 Ant Group Co., Ltd..备案号:京ICP备15032932号-38
Site search
Documentation and examplesType to start searching

Search documentation, APIs, and examples

↑↓Select↵OpenEscClose