Replies: 2 comments
-
I think I figured what's the issue. For mini-coi.js to work it needs to be in the root directory, currently it's being loaded from /assets/scripts/minicoi.js, how do I move it to root directory so my src becomes |
Beta Was this translation helpful? Give feedback.
0 replies
-
Done, resolved :) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Checklist
How did you create the site?
Generated from
chirpy-starter
Description
Hi, I am trying to use the pyscript terminal worker (https://docs.pyscript.net/2024.2.1/user-guide/terminal/) in one of my markdown files and for that we are required to have proper response headers set, since the website will be hosted over github so I don't have control over the response headers and the solution to it is to use the mini-coi.js. But I am unable to register a service worker despite trying everything. I have modified the head.html and included it in my _include folder with the following code added to already written code:
_include/head.html:
terminalexample.md:
I even tried registering the Service worker using java script but I can only see a single service worker registered in the DevTools:
Console:
Service Workers:
The Same thing works fine at : https://terminal.rohsec.com , I am trying to achieve the same thing(the terminal console) here in my terminalexample markdown file but this won't work
The website in action: https://rohsec.github.io/terminal/
Operations you have already tried
This is what I have tried till now:
_include/head.html
_tabs/terminalexample.md
Terminal:
<script type="mpy" src="/assets/scripts/main.py" terminal worker sync></script>Ensured HTTPS is Enabled [github pages]
Still, I keep getting the
and on checking registered service workers, I don't see minicoi and see only one already registered service worker called
Anything else?
No response
Beta Was this translation helpful? Give feedback.
All reactions