You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've noticed the following is also considered a side effect violation:
functionSomeReactComponent(){ ... }// ❌ this is reported as a top level side effect violationSomeReactComponent.displayName='MyComponent';
is this expected?
I think it's reasonable to provide an option to allow this pattern. Even though it can be quite "dangerous" (e.g. you can add a new property to an object from another module), in the described case it's pretty reasonable to want to add a property while there's not workaround to add the property at the time the object (a function in this case) is created.
The text was updated successfully, but these errors were encountered:
Summary
Originally posted by @pallymore in #1080 (comment):
I think it's reasonable to provide an option to allow this pattern. Even though it can be quite "dangerous" (e.g. you can add a new property to an object from another module), in the described case it's pretty reasonable to want to add a property while there's not workaround to add the property at the time the object (a function in this case) is created.
The text was updated successfully, but these errors were encountered: