/// import { computed, Default, pattern, UI } from "commontools"; export default pattern<{ value?: Default }>(({ value }) => { // This computed will fail silently (console.log in computed) const poisoned = computed(() => { console.log("debug:", value); // force an error thrown directly as another repro case if console.log doesn't throw throw new Error("I am a poisoned computed"); // deno-lint-ignore no-unreachable return `got: ${value}`; }); // This computed is fine const healthy = computed(() => `healthy: ${value}`); return { $NAME: "Silent Computed Crash Repro", [UI]: ( Silent computed crash repro 1. Direct value: {value} 2. Healthy computed: {healthy} 3. Poisoned computed: {poisoned} 4. Static text with poisoned: PREFIX-{poisoned}-SUFFIX 5. This should always render ), }; });