|
|
|
@ -1,5 +1,5 @@
|
|
|
|
|
import { STATE_SYMBOL } from '../../../constants.js';
|
|
|
|
|
import { effect, render_effect } from '../../../reactivity/effects.js';
|
|
|
|
|
import { destroy_effect, effect, render_effect } from '../../../reactivity/effects.js';
|
|
|
|
|
import { untrack } from '../../../runtime.js';
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -43,15 +43,13 @@ export function bind_this(element_or_component, update, get_value, get_parts) {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
effect(() => {
|
|
|
|
|
return () => {
|
|
|
|
|
// Defer to the next tick so that all updates can be reconciled first.
|
|
|
|
|
// This solves the case where one variable is shared across multiple this-bindings.
|
|
|
|
|
effect(() => {
|
|
|
|
|
if (parts && is_bound_this(get_value(...parts), element_or_component)) {
|
|
|
|
|
update(null, ...parts);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
if (parts && is_bound_this(get_value(...parts), element_or_component)) {
|
|
|
|
|
update(null, ...parts);
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|