-
Notifications
You must be signed in to change notification settings - Fork 0
Debugger
Henri edited this page Feb 4, 2024
·
2 revisions
When debugging complex applications, you can create a Debugger from your app that you can inject in your browser console.
import { Debugger } from "@scv/cells";
// point to your app main Sheet
const debug = new Debugger(sheet);
window["debug"] = debug;
// you can also add a shortcut to print
window["p"] = (cell: number) => debug.p(cell);
Then, use debug.[command]
in the console.
h -- this help
w(id...) -- watch cells
aw(name) -- auto-watch cells with matching name
uw(id...) -- unwatch cells
p(id) -- print a cell and its deps
s("...") -- search cell names
e -- show all cell errors
u -- show all undefined cells
dot -- generate graphviz dot graph