Skip to content

Dropdown button destroyPopupOnHide prop not working #33433

@balboFK

Description

@balboFK
  • I have searched the issues of this repository and believe that this is not a duplicate.

Reproduction link

Edit on CodeSandbox

Steps to reproduce

Click the popup to open and click again to close, look up the dom tree, the div created by popup will no be cleared.
Also the browser shows a console warning for the prop.

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

What is expected?

The div created by the popup to be cleared and the browser to not throw any warnings.

What is actually happening?

The div is not being cleared and the browser is throwing warnings.

Environment Info
antd 4.18.0
React react: 17.0.2
System Windows 10
Browser Brave

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedThe suggestion or request has been accepted, we need you to help us by sending a pull request.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions