Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Avoid using bind multiple times #203

@pwolaq

Description

@pwolaq

I have noticed that there are many places* where bind is used in render method, creating a new function on every invocation. This results in unnecessary memory pollution and re-renders, as a result affecting performance.

A proper approach would be to either:

  • Use class property syntax with Babel, or
  • Bind every method once in constructor

* few examples:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions