Skip to content

Narrow type of some lists in the TypeScript typings file #43

@MeGaGiGaGon

Description

@MeGaGiGaGon

Issue type:

  • ➕ Feature request

Short description:

Some functions like inventory are typed to return any[]. While not technically wrong, it could have a more precise typing of ValueItemstack[], which helps with autocomplete.

There are also some functions like nbtWithIntList that take in an any[], though I'm not sure what the type for that would be, or if it would be helpful thanks to #31 still being open.

There are also some functions that could maybe use generics to get a more complete typing, ie operatorMap, though I am not familiar enough with TypeScript to give a concrete suggestion

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Accepted (To Do)

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions