mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-04-20 03:13:30 +00:00
Make saved json more pretty.
This commit is contained in:
parent
840464af93
commit
46b674c9c2
@ -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", {
|
||||||
|
Loading…
Reference in New Issue
Block a user