Hi,
Can someone Please tell if the PWA apps are restricted in certain countries?
client says they are blocked in China.
As far as i know if chrome is there in the mobile system it will be running on that browser, in China’s case google is not used there. also tested throught VPN site [https://www.vpnmentor.com/tools/test-the-great-china-firewall/] if site is blocked or not, mine is working fine
Also, there is a requirement, where videos are to be played offline, currently the API gives a URL of video and that URL is loaded onto an HTML5 Video tag (videos are usually large in size more than 100mb).
client wants the video to be downloaded offline and to be played later in PWA app
such offline downloading and playing the video only via App while one is offline is effectively done in native apps like Youtube, Netflix , etc.
we have restricted sites of USA Client, cant give you any of mine, but here is a E-commerce site of India which is a PWA - https://www.flipkart.com
The Video thing is that there is a videos page on our site which is fetched over a URL and loaded onto the HTML5 player, videos can be 200mb or more. As PWA provides Offline caching and stuff, so they want these videos to be cached offline and played later in offline mode
Should probably just give it a try. I don’t know as much about web dev as game dev. I would imagine you could save the video file into a byte array and then write it to the cache as a file. I did something similar in a game that could record from the users mic. It was written in Flash AS3 (flex). The recording was stored in a a byte array as a .wav. It was then converted to an mp3 byte array. Then it was sent in an external call to web js, which then made a php call to save it on the server. In your case you wouldn’t need to save it to a server, just the cache. Why not try it and then turn off lamp/wamp/mamp and see if the video will play.
I could probably help more if you were working in c++, or c#, or other down to the metal language. For the above example, I had to teach myself just enough js and php to get the job done…and that was back in 2011 or 2012.
If there’s anything I can’t answer, I recommend checking stackoverflow.com . There may already be a thread there that answers your questions. If not make a new post.
The thing is the site in a browser cannot do things which apps can do, like accessing file system(storing and reading back in the dedicated video player) for offline storage like Netflix or amazon prime mobile apps.
LOL cookies will degrade the performance of the website and will put a damn bad sign on ReactJS’ performance, if videos were of lower sizes then would have done something, but each browser on different OS gives particular amount of cache i.e around 5-15% of the primary drive’s free space.
@gord0 apparently my boss wants site to be converted into app using something like cordova and then make it work like netflix.
Rest for china issue, removed the google libraries via cdn and kept it in the build(local).