
Ask HN: “Add to Home Screen” webapps - oyeanuj
Has anyone here built or supported &quot;Add to Home Screen&quot; mobile-web apps? I&#x27;m curious to hear people&#x27;s experiences, especially for apps that have logged-in experiences.<p>I&#x27;ve a site that uses passwordless magic links to log you in, and strangely there seems to be very little online about how well logged-in experiences work, and best practices to implement them.
======
openthc
I've made a few of them; there are some tricks -- especially if you want them
to stay authenticated. AddToHome trick will reference the page they are
currently on, so I only allow it on the /home or /dashboard like pages -- if
they add to home from a deep-link it will always land them there.

And there's like a dozen meta tags for the Apple/Android systems to get right.

It basically creates a hosted-web-view with less "chrome" around there -- no
address bar and stuff like that -- so you'll need to solve the 'back-button'
problem too.

~~~
oyeanuj
Could you share those tricks around staying authenticated? Since cookies
aren't shared between regular browser and "HomeScreen" app, how do you make
that happen?

------
atum47
I'm having some trouble with this right now. Just posted a second ago. I can't
figure out the right way to cache your web app so chrome would prompt the user
to install it.

If someone could help, take a look at my repo:

[https://github.com/victorqribeiro/create](https://github.com/victorqribeiro/create)

