DataTables 2.0 and TypeScript types for extensions
DataTables 2.0 and TypeScript types for extensions
sadeghbarati
Posts: 14Questions: 4Answers: 0
Link to test case: https://stackblitz.com/edit/vitejs-vite-ggumwx
Debugger code (debug.datatables.net):
Error messages shown:
Argument of type '{ dom: string; buttons: string[]; }' is not assignable to parameter of type 'Config'.
Object literal may only specify known properties, and 'buttons' does not exist in type 'Config'.(2345)
Description of problem: I have typescript errors with DataTables Extensions imports how to fix typescript errors
Thanks
Sadegh
This question has an accepted answers - jump to answer
Answers
Sry it's ok on Stackblitz after I refreshed the tab, but idk why my IDE still got the problem
Two things spring to mind:
@types/datatables.net
or any of the other @types for datatables.net. All of my libraries contain their own Typescript definiations and you don't need any external types.Allan