Quickstart
Inputs
We include the Observable Inputs (opens in a new tab) library.
// Cell 1
viewof myTextInput = Inputs.text("Enter text")
// Cell 2
Button("log", () => {
console.log(myTextInput)
});
Mutable
Occasionally you'll want a mutable cell.
// Cell 1
mutable cell = 0
// Cell 2
Button("inc", () => {
mutable cell = cell + 1
});
GraphXR API
Access GraphXR API with the built-in gxr
object.
Button("select", () => {
gxr.nodes().select();
});
See the API Reference for more.