mbasso / react-decoration

A collection of decorators for React Components
MIT License
631 stars 24 forks source link

[WIP] Decorator chaining #11

Closed jneuendorf closed 1 year ago

jneuendorf commented 5 years ago

Decorators should be chainable.

This includes the @autobind decorator which uses a different descriptor type than all other decorators in this lib. Thus, currently something like this cannot be used:

class {
  a = 42

  @debounce(500)
  @autobind
  myMethod() { return this.a }
}

See #10 for details.