fix(journal): re-init reactivity and drop var del
Make the reactivity engine re-initialize when the loaded declarations change instead of only at import. ensureReactivity() reads the live completions signal, compares a signature, and rebuilds from the store (with exact bases) only when needed; dispatchCommand calls it before each dispatch. Remove the unused DispatchContext.declarations/tagModifiers fields, which were mount-time snapshots and could not be trusted. Build initReactivity's maps into locals and commit only after the circular check passes, so a failed re-init leaves the previous engine intact; clear inFlight on commit. Drop the unreachable var "del" action from the schema, render, and reducer.
This commit is contained in:
@@ -48,7 +48,7 @@ export { StreamMessageCard } from "./StreamMessage";
|
||||
export { ComposePanel } from "./ComposePanel";
|
||||
export { JournalInput } from "./JournalInput";
|
||||
export { DynamicForm } from "./DynamicForm";
|
||||
export { useJournalCompletions } from "./completions";
|
||||
export { useJournalCompletions, ensureReactivity } from "./completions";
|
||||
export { dispatchCommand } from "./command-dispatcher";
|
||||
export type { DispatchContext, DispatchResult } from "./command-dispatcher";
|
||||
export { parseInput } from "./command-parser";
|
||||
|
||||
Reference in New Issue
Block a user