mirror of
https://github.com/odoo/owl.git
synced 2025-10-06 19:59:41 +07:00
[REF] component: remove onDestroyed, implement onWillDestroy
This commit is contained in:
committed by
Samuel Degueldre
parent
03f34a38dc
commit
0831bb54e3
+4
-4
@@ -1,7 +1,7 @@
|
||||
import {
|
||||
App,
|
||||
Component,
|
||||
onDestroyed,
|
||||
onWillDestroy,
|
||||
onMounted,
|
||||
onPatched,
|
||||
onWillRender,
|
||||
@@ -210,9 +210,9 @@ export function useLogLifecycle() {
|
||||
logStep(`${name}:willUnmount`);
|
||||
});
|
||||
|
||||
onDestroyed(() => {
|
||||
expect(name + ": " + status(component)).toBe(name + ": " + "destroyed");
|
||||
logStep(`${name}:destroyed`);
|
||||
onWillDestroy(() => {
|
||||
expect(status(component)).not.toBe("destroyed");
|
||||
logStep(`${name}:willDestroy`);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user