Opening repl browser with justpy
Hi everyone! Has somene got any idea of how to run a justpy application ( a web page) so that a user may see it ? In other words, how can somene see the repl webbrowser open? Would it be fine to just use webbrowser library to open and see the local repl browser? Thanks in advance!
@adityavengata, @xfinnbar and @wumi4, thank you all. Today the repl manage to load justpy library. I guess yesterday the repl server had a quirk. Unfortunately, even though I used the commands you had advised, I didn´t make it. I´ve just sent a message to "[email protected]". I hope they may enlighten me.
@smfrederico
Thats super complex, just use webbot to trigger the browser:
from webbot import Browser repl = Browser() repl.go_to("https://google.com")
If your justpy works fine, you can then open a new tab and connect to the localhost or any web page
The repl has not loaded justpy, even though I had typed pip install
@smfrederico Use the packages button on the sidebar. It looks like a cube.
I added these lines "webbrowser.open('https://replit.com:8001/')", but to no avail :(
I don't know. Try typing firefox
to the shell or something like that. Maybe it will trigger the GUI.
https://justpy.io/reference/justpy/#:~:text=The%20justpy%20command%20starts%20the%20web%20sever%20and,be%20the%20last%20command%20in%20the%20program%20file.
This option should be able to start webserver in replit.