yavin-dev / framework

A framework for rapidly building production quality analytics applications
https://yavin.dev
MIT License
85 stars 35 forks source link

Fix: Delete action that destroys the component blows up #1587

Closed daniellevinson closed 2 years ago

daniellevinson commented 2 years ago

Change toggle helper to mut. toggle uses set. If deleteAction causes the component to be destroyed, an Assertion Failed: calling set on destroyed object: [object Object].isDeleting = false error is thrown. (we update isDeleting to false once deleteAction resolves). the added test would've thrown when using toggle.

License

I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.