better way of handling injection of webmanifests

This commit is contained in:
Lee Salminen 2022-07-05 15:05:31 -06:00
parent 80f8d83548
commit 2cb87d96f2
3 changed files with 5 additions and 1 deletions

View file

@ -1,4 +1,3 @@
<link rel="manifest" href="/manifest/{{ user.id }}.webmanifest" />
{% extends "base.html" %}
<!---->
{% from "macros.jinja" import window_vars with context %}

View file

@ -145,6 +145,7 @@ async def wallet(
"user": user.dict(),
"wallet": wallet.dict(),
"service_fee": service_fee,
"web_manifest": f"/manifest/{user.id}.webmanifest"
},
)

View file

@ -16,6 +16,10 @@
/>
<meta name="mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-capable" content="yes" />
{% if web_manifest %}
<link async="async" rel="manifest" href="{{ web_manifest }}" />
{% endif %}
{% block head_scripts %}{% endblock %}
</head>