Closed tidou44 closed 2 years ago
Nope, this is not possible. There're many ways of using the decorator. It can decorate a directive that is placed in a different file, a component can extend the directive, and untilDestroyed
is used within this component. Considering the ESLint rule, that would've given an error (because AST is available only per file), but the usage is actually correct.
Hello I have been using until-destroy for a few months and I find this library very useful. However, sometimes I use untilDestroyed(this) and forget to add the @until-destroy() decorator, which gives a runtime error. Is there a way (eslint rule for example) to ensure that the decorator is present in all components using until-destroyed(this)?