How to make a PWA with streamlit

Hello!
I wanna make a PWA using streamlit.

So i make a manifest.json and try to add <link rel=‘manifest’…> in html header tag.

But i dont know how to add.
Please teach me how to add…

Thank you

4 Likes

Hi @Soogle44, welcome to the Streamlit community!

Could you be more specific about what you are trying to do? From the context, it looks like you are trying to pass manifest.json and want Streamlit to do something with it?

Best,
Randy

Yes, i wanna use manifest.json.

i wanna make app that can be added home screen if it is accessed from smartphones.

thank you

3 Likes

Hi, I developed a beautiful webapp but I need it to be able to work offline. The first idea I have is to convert it into a PWA but I have not found documentation on how to achieve it.

Hi @Renzo_Gamero_Rodrigu, welcome to the Streamlit community!

As far as I know, there is no way currently to make a PWA from a Streamlit app, as Streamlit requires having an open websocket connection between the Python backend and JavaScript front-end.

Best,
Randy

1 Like

But is this possible with deployment on heruko?

Sorry, I’m gonna throw some mud at the wall here and hope it sticks because this feature would be immensely valuable. Not sure if anything provides a convenient way to do this coupled with a convenient way to make web apps.

What if, for the purpose of a PWA, the backend were replaced (while offline) with a local backend stored somewhere local on the device. When online again, the websocket connection would be with home, not the local backend.

Any chance?

Edit: What are these?

Edit 2: For the record, at the time of this writing, the Anvil landing page here claims to be similar to Streamlit while offering PWA out-the-box. Maybe worth checking into: Anvil | Why Choose Anvil over Streamlit?

Edit 3: Not sure how… But if someone can point me in a good direction I’d be happy to contribute to this effort with my own time. PWA OTB with Streamlit would be killer.

Imagine many of the benefits developers get via git, but now as a convenient tool given to engineers while rapidly developing applications for users. The user gets to realize those benefits; work offline, sync later. This is hard to accomplish at the moment. If it were easier… Ground breaking if you ask me.