We have a requirement to develop a hybrid app for iOS and Android platform and also there is a need to support desktop( Web app). Is it possible to use the same codebase to host the app as a web app which will run on browsers like Chrome, Safari?
Ok. Thank you. We need to provide offline capability on Mobile app. We might go for SQLite which I believe will not work for Web app. What other options are available to provide offline feature on desktop?
nothing, but i only recommend stuff i used on my own. I heard of ionic storage, but i think the api is a little bit limited. But you are write, this is another possible approach :).
In some cases https://github.com/techfort/LokiJS will help you, too. If you only need to save a few non critical data you can go with lokijs as an fast javascript in memory db. There is also a File-Adapter for cordova file, where you can sync the in-memory with the filesystem.
If u’re looking for maintaining a same code base for all platforms, Webview of Android and IOS is the API you need to know. However, you definitely will find out the differences of cross-browsers’ behavior, and would also start to think having the features from the mobile devices that can offer.
Then, you’re very possible to involve coding for Android (java) )and IOS (swift/objective C), or will go looking what is Phonegap and Cordova.
Anyway, Webview serves your primary objective.
AFAIK there is a WebSQL Cordova Plugin which behaves exactly like WebSQL, but uses SQLite under the hood. Sounds good, but I haven’t tried it yet. OK, there’s still the problem with Desktop Web…