Can be used with this tutorial: IOS: Make your website run as an app
Implementation effect:
↑, Prompt to install the website as an app when visiting
Tutorial:#
Create a manifest.json file in the root directory of the website
Content reference: (Remove comments when using)
{
"background_color": "#ffffff (background color)",
"description": "(website description)",
"display": "standalone (display type, currently parameter for windowed display)",
"icons": [
{
"sizes": "192x192 (icon size)",
"src": "icon-192x192.png (fill in the icon address)",
"type": "image/png (icon file type)"
}
],
"name": "(website name)",
"short_name": "(short name)",
"start_url": "/ (website homepage)",
"theme_color": "#000000 (theme color)"
}
! For more parameter introductions, please refer to this document on MDN: Web App Manifest
Pay attention to correct JSON format when writing: You can use this website to validate and fix
Add the following code inside the tag of the webpage:
<link rel="manifest" href="/manifest.json">
Refreshing the webpage should display the above prompt. If not, please clear the cache.