← Back to Kontasks
Flow Graph Lazy Loading Disabled
Removed lazy loading to fix graph not rendering on mobile
Output
🔧 Flow Graph - Lazy Loading Disabled
✓ Fixed - Graph now renders inline instead of via fetch
Problem
The flow graph at /gv/flows was stuck on "Loading graph..." with skeleton placeholders visible but the actual vis-network graph never rendered.
Root cause: Two layers of async loading (fetch API call + CDN script load) was failing silently on mobile browsers.
Solution
Changed from lazy loading (fetch /api/gv/flows/graph-data) to inline rendering.
// Before: Lazy load via fetch - const response = await fetch('/api/gv/flows/graph-data'); - document.getElementById('graph-container').innerHTML = html; // After: Render inline in page + const graphData = generateFlowsOverviewGraphData(flows, kontasksByFlow); + renderVisGraphContainer("flows-graph", graphData, {...});
Changes
| File | konui/src/views/gv-flows.ts |
| Lines changed | +13 / -33 |
| Commit | b77e02b3 |
⚠️ Note: The
/api/gv/flows/graph-data API endpoint still exists and works - it can be used by other clients if needed.
🔄 Konui restarted - Please refresh the /gv/flows page to test.
Quick Actions
Original Request
No layout configured
Details
Type
General
Status
Completed
Scope
vibetools
Tags
flowsuimobilefix
Created
10 Jan 2026, 7:03 pm
Updated
10 Jan 2026, 7:03 pm
Created By
claude
📋 Claude's Context
Session
ses_7c4eba4a...
🔗 Git Commit
b77e02b3
Raw Data
{
"id": "ae1fbbf4-ef13-4328-95cf-510c083ae9f7",
"type": "general",
"status": "completed",
"title": "Flow Graph Lazy Loading Disabled",
"description": "Removed lazy loading to fix graph not rendering on mobile",
"context": {
"output": "<div style=\"background:#1e1e1e;color:#e0e0e0;padding:20px;border-radius:8px;font-family:'Consolas','Monaco',monospace;\">\n<h2 style=\"font-family:sans-serif;color:#fff;margin:0 0 16px 0;\">🔧 Flow Graph - Lazy Loading Disabled</h2>\n\n<div style=\"background:#16a34a22;border:1px solid #22c55e;padding:12px;border-radius:6px;margin-bottom:16px;\">\n<span style=\"color:#22c55e;font-weight:bold;\">✓ Fixed</span> - Graph now renders inline instead of via fetch\n</div>\n\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<h3 style=\"color:#ef4444;margin:0 0 12px 0;\">Problem</h3>\n<p style=\"margin:0;line-height:1.6;\">\nThe flow graph at <code style=\"background:#374151;padding:2px 6px;border-radius:4px;\">/gv/flows</code> was stuck on \"Loading graph...\" with skeleton placeholders visible but the actual vis-network graph never rendered.\n</p>\n<p style=\"margin:12px 0 0 0;color:#9ca3af;\">\n<strong>Root cause:</strong> Two layers of async loading (fetch API call + CDN script load) was failing silently on mobile browsers.\n</p>\n</div>\n\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<h3 style=\"color:#22c55e;margin:0 0 12px 0;\">Solution</h3>\n<p style=\"margin:0;line-height:1.6;\">\nChanged from lazy loading (fetch <code>/api/gv/flows/graph-data</code>) to <strong>inline rendering</strong>.\n</p>\n<pre style=\"background:#374151;padding:12px;border-radius:6px;margin:12px 0 0 0;overflow-x:auto;font-size:0.85rem;\">\n<span style=\"color:#7f848e;\">// Before: Lazy load via fetch</span>\n<span style=\"color:#ef4444;\">- const response = await fetch('/api/gv/flows/graph-data');</span>\n<span style=\"color:#ef4444;\">- document.getElementById('graph-container').innerHTML = html;</span>\n\n<span style=\"color:#7f848e;\">// After: Render inline in page</span>\n<span style=\"color:#22c55e;\">+ const graphData = generateFlowsOverviewGraphData(flows, kontasksByFlow);</span>\n<span style=\"color:#22c55e;\">+ renderVisGraphContainer(\"flows-graph\", graphData, {...});</span>\n</pre>\n</div>\n\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<h3 style=\"color:#61afef;margin:0 0 12px 0;\">Changes</h3>\n<table style=\"width:100%;border-collapse:collapse;\">\n<tr style=\"border-bottom:1px solid #3d3d3d;\">\n<td style=\"padding:8px;color:#7f848e;\">File</td>\n<td style=\"padding:8px;\"><span style=\"color:#e5c07b;\">konui/src/views/gv-flows.ts</span></td>\n</tr>\n<tr style=\"border-bottom:1px solid #3d3d3d;\">\n<td style=\"padding:8px;color:#7f848e;\">Lines changed</td>\n<td style=\"padding:8px;\"><span style=\"color:#22c55e;\">+13</span> / <span style=\"color:#ef4444;\">-33</span></td>\n</tr>\n<tr>\n<td style=\"padding:8px;color:#7f848e;\">Commit</td>\n<td style=\"padding:8px;\"><code style=\"background:#374151;padding:2px 6px;border-radius:4px;\">b77e02b3</code></td>\n</tr>\n</table>\n</div>\n\n<div style=\"background:#f59e0b22;border:1px solid #f59e0b;padding:12px;border-radius:6px;margin-bottom:16px;\">\n<span style=\"color:#f59e0b;\">⚠️ Note:</span> The <code>/api/gv/flows/graph-data</code> API endpoint still exists and works - it can be used by other clients if needed.\n</div>\n\n<div style=\"background:#3b82f622;border:1px solid #3b82f6;padding:12px;border-radius:6px;\">\n<span style=\"color:#3b82f6;\">🔄 Konui restarted</span> - Please refresh the /gv/flows page to test.\n</div>\n\n</div>",
"commitSha": "b77e02b3",
"requestedAt": "2026-01-10T09:00:00Z",
"requestId": "75aafaad-3628-46df-94cd-13c53ed2f6ac",
"choices": [
{
"label": "Test the fix",
"value": "Navigate to /gv/flows and switch to Graph view to verify it loads correctly now",
"primary": true
},
{
"label": "Revert change",
"value": "Revert the lazy loading removal if it caused other issues"
},
{
"label": "View code diff",
"value": "Show me the full git diff for commit b77e02b3"
}
]
},
"createdBy": "claude",
"createdAt": "2026-01-10T09:03:06.624Z",
"updatedAt": "2026-01-10T09:03:06.782Z",
"requestId": "75aafaad-3628-46df-94cd-13c53ed2f6ac",
"scope": "vibetools",
"tags": [
"flows",
"ui",
"mobile",
"fix"
],
"sessionId": "ses_7c4eba4a-596",
"flowId": "flow_01KEHQ5A6Y7SHWCMHHZYGBC592",
"flowLinks": [
{
"flowId": "flow_01KEHQ5A6Y7SHWCMHHZYGBC592",
"edgeType": "evidence",
"createdAt": "2026-01-10T09:03:06.624Z"
}
]
}