lucaslealdev / A2H-nice-ask

A more friendly way to ask the user to install your PWA using beforeinstallprompt.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

A2H-nice-ask

A more friendly way to ask the user to install your PWA using beforeinstallprompt.

Why?

The default a2h prompt changes between browsers and devices, leaving you no option of styling. This repository wants to give you an option. With A2H-nice-ask you can change the way you ask your users to install your app, and also delay the prompt for some time (the default is 12 hours) so the user don't get annoyed. This was inspired by the google developers guide for app-install-banners written by Pete LePage.

Lockr?

Lockr is "a minimal API wrapper for localStorage". I made a fork from the original repository to add the expires option. You can check my fork here.

How to use

Include the needed files (js and css) and call a2hAskNicelly() before the body tag end.

Screenshot

working screenshot

About

A more friendly way to ask the user to install your PWA using beforeinstallprompt.

License:MIT License


Languages

Language:JavaScript 74.4%Language:CSS 19.8%Language:HTML 5.8%