LiveView, serving web views to browser and (hybrid/PWA) mobile app?

Hey alchemists! :woman_scientist: :scientist:

I think a lot about building a web app friendly from desktop to mobile. Iā€™m convinced by the fact managing the state as much as possible in the back-end is a very nice approach to minimize work and bugs. Maybe you guessed, I think about LiveView to communicate between the back-end and the user UI.

My wish:

  • on desktop, the experience is nice via web browser
  • on mobile, the experience is nice via web browser
  • on mobile, the experience is nice and encouraged via a mobile app (main topic of this post)

I see two different approaches to design the mobile experience via a mobile app reusing the Phoenix Liveview powered views:

  • building a PWA (Progressive Web App), however Iā€™m not sure it is pragmatic with LiveView SSR
  • building two minimal hybrid mobile apps (Android and iOS), with features written natively for tiny generic features (like splash screen, notifications, no network behavior, etc.) and pushing the main content as a web view (see this exemple or this other one I found writting this)

Do you have some experience feedbacks on this in the Phoenix/LiveView ecosystem? :face_with_monocle:

The second option take inspiration from this talk by Sam Stephenson from Basecamp about how they used Turbolinks (now named Turbo) to serve their web app from desktop to mobile via Rails SSR.

PS: note I already watched about LiveView Native which is seems considered as R&D right now, my point here is web based content.

1 Like

You are describing something very much like this

https://hexdocs.pm/desktop/readme.html

2 Likes