We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2bb8928 commit e68ddeeCopy full SHA for e68ddee
1 file changed
bin/observable-prerender
@@ -17,6 +17,7 @@ const formatOptions = new Set([
17
"svg",
18
"text",
19
"txt",
20
+ "json",
21
]);
22
23
program
@@ -168,6 +169,11 @@ program
168
169
if (format === "html") return notebook.html(cell, path);
170
if (format === "text" || format === "txt")
171
return writeFileSync(path, await notebook.value(cell));
172
+ if (format === "json")
173
+ return writeFileSync(
174
+ path,
175
+ JSON.stringify(await notebook.value(cell))
176
+ );
177
return notebook.screenshot(cell, path, { type: format });
178
})
179
);
0 commit comments