mirror of
https://github.com/thepaperpilot/Advent-Incremental.git
synced 2025-01-19 03:51:37 +00:00
Make optional components handle false-y values better
This commit is contained in:
parent
5f1b2e7178
commit
65fbeb73ff
1 changed files with 1 additions and 1 deletions
|
@ -229,7 +229,7 @@ export function computeOptionalComponent(
|
|||
const comp = shallowRef<Component | "" | null>(null);
|
||||
watchEffect(() => {
|
||||
const currComponent = unwrapRef(component);
|
||||
comp.value = currComponent == null ? null : coerceComponent(currComponent, defaultWrapper);
|
||||
comp.value = !currComponent ? null : coerceComponent(currComponent, defaultWrapper);
|
||||
});
|
||||
return comp;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue