Skip to content

Incorrect usage of Exclude in type declarations #2257

Closed
@ethereon

Description

@ethereon

I believe these two should be using Omit<DotOptions, "symbol"> rather than Exclude<DotOptions, "symbol">:

export function circle(data?: Data, options?: Exclude<DotOptions, "symbol">): Dot;

export function hexagon(data?: Data, options?: Exclude<DotOptions, "symbol">): Dot;

(Exclude filters out members from unions, whereas Omit filters out properties)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn’t working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions