5

I have this TypeScript error:

Type 'xyz' is not assignable to type 'TableComponents'.

So I need to cast my type as TableComponents. But this interface is not available when I try to import it using:

import { TableComponents } from 'antd/lib/table/interface';

The interface is listed here as being part of the library.

How do I import it to my React project?

Mr. Robot
  • 1,334
  • 6
  • 27
  • 79

1 Answers1

0

You might look at an outdated version of interface.tsx.

This is the version on master and there is no TableComponents.

The antd branch should fit the lib version you use.

zerocewl
  • 11,401
  • 6
  • 27
  • 53