progressive-web-apps

How to remove chrome icon add to home screen prompt

纵饮孤独 提交于 2019-12-24 23:53:31
问题 I am working with PWA app and I have an issue with add to home screen prompt. I need to remove the chrome badge from the app icon underneath. Here is my manifest.json { "short_name": "App Name", "name": "App Name", "icons": [ { "src": "...", "sizes": "192x192", "type": "image/png" }, { "src": "...", "sizes": "512x512", "type": "image/png" }, { "src": "...", "sizes": "64x64", "type": "image/png" } ], "start_url": "/login", "display": "standalone", "theme_color": "#ffc107", "background_color":

External file loading reference loading issue due to dynamic routing in angular?

↘锁芯ラ 提交于 2019-12-24 20:52:47
问题 I am Using Angular Universal project. In that i have configured fully dynamic routing like below. { path: ':locale', component: HomePageCategory }, { path: ':locale/:id', component: HomePageCategory }, Now i have added PWA so manifest reference was added in html file like below. <link rel="manifest" href="./manifest.webmanifest"> issue raised like below 1. Failed to load resource: the server responded with a status of 404 (Not Found) 2. Manifest: Line: 1, column: 1, Unexpected token. can you

Angular 5: Function calls are not supported in decorators

不羁岁月 提交于 2019-12-24 19:43:17
问题 I am building a PWA from my Angular app and I am getting the following error when I run ng build --prod : ERROR in app\app.module.ts(108,64): Error during template compile of 'AppModule' Function calls are not supported in decorators but 'Environment' was called in 'environment' 'environment' calls 'Environment'. However, it makes no sense because I added export to the class as you can see here: environment.prod.ts import { BaseEnvironment } from './base-environment'; import {

How can I wake up service worker when browser closed

我的梦境 提交于 2019-12-24 19:15:04
问题 I am playing with service worker stuff. I already made it as well as manifest json. I want to trigger service worker start after following scenario: Added push integration and sending push notification from server side. Received it in client side, but only if I am in my application page. Here are the steps what I want to try to start service worker: I opened the web page for the first time Service - Worker is installed I totally close the browser I re-open the browser Now I need to trigger

IOS camera returns black screen after leaving pwa

≯℡__Kan透↙ 提交于 2019-12-24 18:39:38
问题 I'm using html file input to open camera and take photos for my PWA. <input type="file" accept="image/*" capture="camera" name="photo" id="photo-input-js" data-project-id="<?php echo $projectId ?>"> // this element triggers the input <li class="menu-item <?php echo $current_page == 'camera' ? 'is-active' : '' ?>" id="camera-tab"> <a href="<?php echo site_url("photos/openCamera/". $projectId) ?>" id="open-camera-js"> <div class="icon icon-camera"></div> <span class="d-none d-md-block ">Camera<

How To Add Service Worker In React Project

烈酒焚心 提交于 2019-12-24 17:09:30
问题 I want to add service worker in my react project. Project is ready the default Service seems not to works. Even When I try to import this, it gives this error: Attempted import error: './registerServiceWorker' does not contain a default export (imported as 'registerServiceWorker'). Furthermore, how to add files to be cached in the default version serviceWorker file. If I add my own custom serviceWorker file just like for no-react (framework) application, will it works for react case?

Manually replaying requests queued by workbox-background-sync

微笑、不失礼 提交于 2019-12-24 09:08:04
问题 I am working on offline support in my PWA app. I am using workbox for that. This is my current code: const addToFormPlugin = new workbox.backgroundSync.Plugin('addToForm'); workbox.routing.registerRoute( RegExp('MY_PATH'), workbox.strategies.networkOnly({ plugins: [addToFormPlugin] }), 'POST' ); The code seems to works fine on my computer. However, once I run the app on the phone it takes ages to upload requests stored in IndexedDB. I know that it happens on the SYNC but it seems to take at

publishing PWA on app stores : google play and ios itunes

青春壹個敷衍的年華 提交于 2019-12-24 04:26:26
问题 Is there a way to publish an app on publishing PWA on app stores google play and ios itunes. Without creating a buggy with cordova which creates a tons of issues to maintain. 回答1: Yes there is way to publish your PWAs to Android AppStore. TWAs Trusted Web Activities are a new way to integrate your web-app content such as your PWA with your Android app using a protocol based on Custom Tabs. TWAs uses the Digital Asset Links protocol and API enable an app or website to make public, verifiable

Hybrid App depending on server side patch

僤鯓⒐⒋嵵緔 提交于 2019-12-24 02:59:24
问题 I want to make a Hybrid app that can be frequently patched and immediately reflected like web site. Native apps take too much time to get Store's approval every time. So searched for Cordova, Xamarin, React Native and so on..., but not sure about which one would be the best for me. I won't use complicated functions or logic and don't need high performance. It's like a commerce shopping app. Any suggestions? Thank you in advance. 回答1: If you don't want the store approval process and app update

Workbox is caching only time stamps to indexDb, how to intercept with json data in indexDb?

天大地大妈咪最大 提交于 2019-12-24 00:33:27
问题 Below route defines to store json data as MyCachedData in cache storage, and IndexDb only stores the url and timestamp. workboxSW.router.registerRoute('/MyApi(.*)', workboxSW.strategies.staleWhileRevalidate({ cacheName: 'MyCachedData', cacheExpiration: { maxEntries: 50 }, cacheableResponse: {statuses: [0, 200]} }) ); Is it possible to store the json data in the index db only and how can you define it to intercept (add, update, delete) using Workbox? 回答1: No, Workbox relies on the Cache