Skip to content

findDOMNode is deprecated in StrictMode #199

Description

@boatcoder

Started a new CRA to and added withSize like so:

export default withSize()(App);

The console is throwing off warnings like this, so Changes they are a coming!

Warning: findDOMNode is deprecated in StrictMode. findDOMNode was passed an instance of SizeMeReferenceWrapper which is inside StrictMode. Instead, add a ref directly to the element you want to reference. Learn more about using refs safely here: https://fb.me/react-strict-mode-find-node
    in div (created by SizeMePlaceholder)
    in SizeMePlaceholder (created by SizeMeRenderer(App))
    in SizeMeReferenceWrapper (created by SizeMeRenderer(App))
    in SizeMeRenderer(App) (created by SizeMe(App))
    in SizeMe(App) (at src/index.js:9)
    in StrictMode (at src/index.js:8)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions