pwa - fitizens/hugo-modules GitHub Wiki
Progressive Web App
PWA Module
Add the following code to your module list in the config/_default/module.toml
file.
[imports](/fitizens/hugo-modules/wiki/imports)
path = "github.com/gethugothemes/hugo-modules/pwa"
PWA Implementation
Call it, as a partial in your theme head.
<!-- progressive web app -->
{{ partial "manifest.html" . }}
Call it, as a partial in your theme footer.
<!-- progressive web app -->
{{ partial "pwa.html" . }}
Add some following configuration to your config/_default/config.toml
file.
############################# Outputs ##############################
[outputs]
home = ["WebAppManifest"]
############################ Media types ############################
[mediaTypes]
[mediaTypes."application/manifest+json"]
suffixes = ["webmanifest"]
############################ Output Format ###########################
[outputFormats]
[outputFormats.WebAppManifest]
mediaType = "application/manifest+json"
rel = "manifest"