aboutsummaryrefslogtreecommitdiff
path: root/src/debug/Viewer.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/debug/Viewer.tsx')
-rw-r--r--src/debug/Viewer.tsx15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/debug/Viewer.tsx b/src/debug/Viewer.tsx
index c085b3483..24db3f934 100644
--- a/src/debug/Viewer.tsx
+++ b/src/debug/Viewer.tsx
@@ -181,9 +181,12 @@ class Viewer extends React.Component {
}
}
-ReactDOM.render((
- <div style={{ position: "absolute", width: "100%", height: "100%" }}>
- <Viewer />
- </div>),
- document.getElementById('root')
-); \ No newline at end of file
+(async function () {
+ await DocServer.init(window.location.protocol, window.location.hostname, 4321, "viewer");
+ ReactDOM.render((
+ <div style={{ position: "absolute", width: "100%", height: "100%" }}>
+ <Viewer />
+ </div>),
+ document.getElementById('root')
+ );
+})(); \ No newline at end of file