tleunen / react-mdl

React Components for Material Design Lite
https://tleunen.github.io/react-mdl/
MIT License
1.76k stars 255 forks source link

Missing inputRef property in @types/react-mdl #465

Open dsheiko opened 7 years ago

dsheiko commented 7 years ago

When adding a Ref to a React component, the callback receives an object that has property inputRef: <Textfield ref={(el: Textfield) => { this.input = el.inputRef ); }} />

So one can use it e.g. to get the value of the internal input. However TypeScript complains like "error TS2339: Property 'inputRef' does not exist on type 'Textfield'."

Apparently the type definitions package @types/react-mdl simply misses inputRef. Actually there is no mentioning of "inputRef" in @types/react-mdl