"vscode:/vscode.git/clone" did not exist on "c3e61bea2598b028cd28d163238bab94e68f84de"
Commit 46b674c9 authored by comfyanonymous's avatar comfyanonymous
Browse files

Make saved json more pretty.

parent 840464af
...@@ -310,7 +310,7 @@ export class ComfyUI { ...@@ -310,7 +310,7 @@ export class ComfyUI {
$el("button", { $el("button", {
textContent: "Save", textContent: "Save",
onclick: () => { onclick: () => {
const json = JSON.stringify(app.graph.serialize()); // convert the data to a JSON string const json = JSON.stringify(app.graph.serialize(), null, 2); // convert the data to a JSON string
const blob = new Blob([json], { type: "application/json" }); const blob = new Blob([json], { type: "application/json" });
const url = URL.createObjectURL(blob); const url = URL.createObjectURL(blob);
const a = $el("a", { const a = $el("a", {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment