Skip to content

Commit

Permalink
Fix relative path for web workers (#212)
Browse files Browse the repository at this point in the history
  • Loading branch information
msujew authored Dec 20, 2023
1 parent 3639d8e commit 5b0e7f3
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions hugo/assets/scripts/arithmetics/arithmetics.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ class App extends React.Component<{}, AppState> {
<select className="ml-4 bg-emeraldLangiumDarker cursor-pointer border-0 border-b invalid:bg-emeraldLangiumABitDarker" onChange={(e) => this.setExample(parseInt(e.target.value))}>
<option value="0">Basic Math</option>
<option value="1">Price calculator</option>
</select>
</select>
</div>
<div className="wrapper relative bg-white dark:bg-gray-900 border border-emeraldLangium h-full w-full">
<MonacoEditorReactComp
Expand Down Expand Up @@ -193,7 +193,7 @@ userConfig = createUserConfig({
languageId: 'arithmetics',
code: examples[0],
htmlElement: document.getElementById('root')!,
worker: '/showcase/libs/worker/arithmeticsServerWorker.js',
worker: '../../showcase/libs/worker/arithmeticsServerWorker.js',
monarchGrammar: syntaxHighlighting
});
const root = createRoot(document.getElementById("root") as HTMLElement);
Expand Down
2 changes: 1 addition & 1 deletion hugo/assets/scripts/domainmodel/domainmodel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ userConfig = createUserConfig({
languageId: 'domainmodel',
code: example,
htmlElement: document.getElementById('root')!,
worker: '/showcase/libs/worker/domainmodelServerWorker.js',
worker: '../../showcase/libs/worker/domainmodelServerWorker.js',
monarchGrammar: syntaxHighlighting
});

Expand Down
2 changes: 1 addition & 1 deletion hugo/assets/scripts/minilogo/minilogo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ userConfig = createUserConfig({
languageId: 'minilogo',
code: code ? decompressFromEncodedURIComponent(code) : examples[0].code,
htmlElement: document.getElementById('root')!,
worker: '/showcase/libs/worker/minilogoServerWorker.js',
worker: '../../showcase/libs/worker/minilogoServerWorker.js',
monarchGrammar: syntaxHighlighting
});
const root = createRoot(document.getElementById("root") as HTMLElement);
Expand Down
2 changes: 1 addition & 1 deletion hugo/assets/scripts/sql/ui.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ userConfig = createUserConfig({
languageId: 'sql',
code: defaultText,
htmlElement: document.getElementById('root')!,
worker: '/showcase/libs/worker/sqlServerWorker.js',
worker: '../../showcase/libs/worker/sqlServerWorker.js',
monarchGrammar: syntaxHighlighting
});

Expand Down
2 changes: 1 addition & 1 deletion hugo/assets/scripts/statemachine/statemachine.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ const langiumGlobalConfig: UserConfig = createUserConfig({
code: defaultText,
htmlElement: document.getElementById('root')!,
textmateGrammar: statemachineGrammar,
worker: '/showcase/libs/worker/statemachineServerWorker.js'
worker: '../../showcase/libs/worker/statemachineServerWorker.js'
});

const root = createRoot(document.getElementById("root") as HTMLElement);
Expand Down

0 comments on commit 5b0e7f3

Please sign in to comment.