aboutsummaryrefslogtreecommitdiffstats
path: root/subprojects/frontend/src/RootStore.ts
diff options
context:
space:
mode:
authorLibravatar Kristóf Marussy <kristof@marussy.com>2022-11-10 14:35:24 +0100
committerLibravatar Kristóf Marussy <kristof@marussy.com>2022-11-10 14:35:24 +0100
commit4971c864a603e0c01f7ad84a23697905d096283b (patch)
treefc2ed2ced39aa50aa98602ad4bd2a9d877577dcd /subprojects/frontend/src/RootStore.ts
parentrefactor: rename CallKind to Polarity (diff)
downloadrefinery-4971c864a603e0c01f7ad84a23697905d096283b.tar.gz
refinery-4971c864a603e0c01f7ad84a23697905d096283b.tar.zst
refinery-4971c864a603e0c01f7ad84a23697905d096283b.zip
feat(web): backend URL configuration
To point the frontend to a backend server, update the config.json file in the website root. The config.json is generated automatically in debug mode and when running from a standalone jar.
Diffstat (limited to 'subprojects/frontend/src/RootStore.ts')
-rw-r--r--subprojects/frontend/src/RootStore.ts21
1 files changed, 10 insertions, 11 deletions
diff --git a/subprojects/frontend/src/RootStore.ts b/subprojects/frontend/src/RootStore.ts
index 54a80501..2e76d66d 100644
--- a/subprojects/frontend/src/RootStore.ts
+++ b/subprojects/frontend/src/RootStore.ts
@@ -23,18 +23,17 @@ export default class RootStore {
23 pwaStore: false, 23 pwaStore: false,
24 themeStore: false, 24 themeStore: false,
25 }); 25 });
26 import('./editor/EditorStore') 26 (async () => {
27 .then(({ default: EditorStore }) => { 27 const { default: EditorStore } = await import('./editor/EditorStore');
28 runInAction(() => { 28 runInAction(() => {
29 if (this.disposed) { 29 if (this.disposed) {
30 return; 30 return;
31 } 31 }
32 this.editorStore = new EditorStore(initialValue, this.pwaStore); 32 this.editorStore = new EditorStore(initialValue, this.pwaStore);
33 });
34 })
35 .catch((error) => {
36 log.error('Failed to load EditorStore', error);
37 }); 33 });
34 })().catch((error) => {
35 log.error('Failed to load EditorStore', error);
36 });
38 } 37 }
39 38
40 dispose(): void { 39 dispose(): void {