34 lines
781 B
Markdown
34 lines
781 B
Markdown
|
# Untitled
|
||
|
|
||
|
https://observablehq.com/@cesare/commarcdiag@1159
|
||
|
|
||
|
View this notebook in your browser by running a web server in this folder. For
|
||
|
example:
|
||
|
|
||
|
~~~sh
|
||
|
npx http-server
|
||
|
~~~
|
||
|
|
||
|
Or, use the [Observable Runtime](https://github.com/observablehq/runtime) to
|
||
|
import this module directly into your application. To npm install:
|
||
|
|
||
|
~~~sh
|
||
|
npm install @observablehq/runtime@5
|
||
|
npm install https://api.observablehq.com/d/d019e1db56ab1d8c@1159.tgz?v=3
|
||
|
~~~
|
||
|
|
||
|
Then, import your notebook and the runtime as:
|
||
|
|
||
|
~~~js
|
||
|
import {Runtime, Inspector} from "@observablehq/runtime";
|
||
|
import define from "@cesare/commarcdiag";
|
||
|
~~~
|
||
|
|
||
|
To log the value of the cell named “foo”:
|
||
|
|
||
|
~~~js
|
||
|
const runtime = new Runtime();
|
||
|
const main = runtime.module(define);
|
||
|
main.value("foo").then(value => console.log(value));
|
||
|
~~~
|