Skip to content

Commit a2898b6

Browse files
fix(demo): use relative path for example.py fetch
1 parent 72650a2 commit a2898b6

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

demo/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ el.btn.addEventListener('click', () => PythonWorker.run(Editor.getCode()));
283283
loadIcons();
284284
PythonWorker.load();
285285

286-
fetch(`/${EXAMPLE_FILE}`, FETCH_OPTS ?? {}).then(r => {
286+
fetch(`./${EXAMPLE_FILE}`, FETCH_OPTS ?? {}).then(r => {
287287
if (!r.ok) throw new Error(`HTTP ${r.status}`);
288288
return r.text();
289289
}).then(code => {

0 commit comments

Comments
 (0)