我尝试将一个React Native 应用的桌面版本变成PWA,但总是遇到相同的报告:lighthouse report
{
"short_name": "test",
"name": "test",
"start_url": "/index.html",
"icons": [
{
"src": "favicon/favicon-512.png",
"sizes": "512x512",
"type": "image/png",
"purpose":"any"
}
,{
"src": "favicon/favicon-144.png",
"sizes": "144x144",
"type": "image/png",
"purpose":"any"
}
],
"app":{
"urls": [
"http://localhost:19006/"
],
"launch": {
"web_url": "http://localhost:19006/"
}
},
"loading":"loading_screen.gif",
"display": "standalone",
"theme_color": "#1E88B5",
"background_color": "#f2f7fc",
"scope": "/"
}
这是根目录:folder structure
任何反馈将不胜感激!
我试着更改图标的“src”属性值,但更改没有反映在lighthouse报告中。我还清除了浏览器缓存。灯塔报告中的其他检查通过,但可安装性检查未通过。
1条答案
按热度按时间lf5gs5x21#
您是否在每次更新manifest.json文件时重新创建一个生产构建(通常使用
npm run build
)?