Skip to content

Got "Does not recognize the 'inputRef' prop" warning after providing TextareaAutosize to OutlinedInput #22253

@liketurbo

Description

@liketurbo
  • The issue is present in the latest release.
  • I have searched the issues of this repository and believe that this is not a duplicate.

Current Behavior 😯

Got warning

React does not recognize the `inputRef` prop on a DOM element.
If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `inputref` instead.
If you accidentally passed it from a parent component, remove it from the DOM element.

Expected Behavior 🤔

How to get rid of the warning?

Steps to Reproduce 🕹

Steps:

  1. Provide TextareaAutosize to OutlinedInput through inputComponent prop.

I set up a simple example in CodeSandbox

Context 🔦

No context

Your Environment 🌎

Tech Version
@material-ui/core 4.11.0
react 16.12.0
react-dom 16.12.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    breaking changeIntroduces changes that are not backward compatible.ready to takeHelp wanted. Guidance available. There is a high chance the change will be acceptedscope: text fieldChanges related to the text field.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions