Debugging
Dev mode without setup#
on automatically on localhost / file:// / ?dev / localStorage['aegis:dev']; every warning prints once with what/why/fix; onWarn() turns warnings into assertions, window.__AEGIS_DEV__ = 'strict' throws AegisWarning; lost-reactivity detectors (E019) catch text(el, count.value), show(count.value > 3, …) and effects that read no signals; reset() isolates tests, root() gives a disposable scope
Errors that explain themselves#
every effect error carries e.aegis = { effect, scope, changed } and the message says which effect, which component and which signals changed; scope.onError() / ctx.onError() catch them, so errorBoundary() finally catches errors after mount; trace(sig) prints who wrote a signal, effect(fn, { trace: true }) prints why it re-ran; a typo in the ctx destructuring gets a did-you-mean
For assistants#
llms.txt (rules + canonical island), AGENTS.md, ERRORS.md (every warning code)