Skip to content

[EuiBasicTable] onChange parameter type unable to be determined leads to any #4011

Closed

Description

@alvarezmelissa87

When using EuiBasicTableProps<T>['onChange'] type - onChange type has multiple options

(criteria: Criteria<T>) => void; | (criteria: CriteriaWithPagination<T>) => void; | undefined

This prevents the onChange parameters from being typed correctly and is implicitly set to any which causes TypeScript to complain. Neither Criteria<T> or CriteriaWithPagination<T> are exported. onChange param has to be explicitly typed.

e.g.
const onTableChange: EuiBasicTableProps<TypeOfItem>['onChange'] = (param) => { ...
Param is incorrectly set as any.

Activity

  1. changed the title [-]EuiBasicTableProps - `onChange` parameter type unable to be determined leads to `any`[/-] [+][EuiBasicTable] `onChange` parameter type unable to be determined leads to `any`[/+] on Sep 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions