summaryrefslogtreecommitdiff
path: root/graph/web/viewer.js
diff options
context:
space:
mode:
authorCliff Click <cliffc@acm.org>2026-09-22 09:32:07 -0700
committerCliff Click <cliffc@acm.org>2026-09-22 09:32:07 -0700
commit1d961838cff168a101069d08a8ab6594f49f0911 (patch)
treef832576181cc396c033707508a50e3d72120b8c6 /graph/web/viewer.js
parent92e3013a4cab12747af9d5484e7caad6fc454b1e (diff)
downloadSimple-1d961838cff168a101069d08a8ab6594f49f0911.tar.gz
Simple-1d961838cff168a101069d08a8ab6594f49f0911.zip
Graph viewer on ch4 and25
Diffstat (limited to 'graph/web/viewer.js')
-rw-r--r--graph/web/viewer.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/graph/web/viewer.js b/graph/web/viewer.js
index 9aaaa154..ed14651f 100644
--- a/graph/web/viewer.js
+++ b/graph/web/viewer.js
@@ -148,6 +148,11 @@ try {
try {
if (message.startsWith("{")) {
frame = JSON.parse(message);
+ if (frame.error) {
+ failure = "Compile error: " + frame.error;
+ updateUI();
+ return;
+ }
if (frame.snap.ver !== 1) throw new Error("Unsupported graph version: " + frame.snap.ver);
} else {
// Earlier chapters still send bare DOT.