Skip to content

Type Error in Nested Donut Example #517

Open
@curran

Description

@curran

I notice that in

packages/dev/src/examples/misc/nested-donut/basic-nested-donut/index.tsx

there is a type error:

Type 'number' is not assignable to type 'string'.

at this line:

<VisNestedDonut
  data={data}
  centralLabel='Central Label'
  centralSubLabel='Sub-label'
  layers={[
    (d: NestedDatum) => d.group,
    (d: NestedDatum) => d.subgroup,
    (d: NestedDatum) => d.value, // <--- Type error on this line here
  ]}

I'm using this as a reference for implementing a Treemap, and I'm skeptical if I should copy this API over to the new component, or if there is something wrong with the example implementation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions