using sqlite database with quasar
-
Hi,
I’m new to quasar and have a general question.
Can anyone, please, share with me the expected way to use the sqlite in the quasar applications.
In the documentation it’s stated that we can use WebStorage . However, I think sometimes we might need something more serious.
I found that there is a Cordova sqlite plugin, and assume it’s possible to use it. But, it’s not clear how to develop using
quasar dev ios
as I assume this would not work in browser.Any thoughts?
Regards,
-
Hi,
You can use Web SQL databases. http://html5doctor.com/introducing-web-sql-databases/
Any cordova plugin would work too. Nothing special to how Quasar works on Cordova. Anything working with a bare bone cordova app will also work with Quasar. -
@rstoenescu
Thanks for the answer and for the library itself.However, do you think that Cordova plugins would be able to work while being under
quasar dev ios
?
Or only after we wrap the application into Cordova and run on the emulator. -
Only after wrapping the app into Cordova and running it on a mobile device or on emulator.
-
Just as a note … some of the browsers support’s this API, see : https://www.tutorialspoint.com/html5/html5_web_sql.htm
And then the workflow becomes much more light.
-
One question: WebSql has not been discontinued?
-
-
Thanks @s-molinari, I’m going to use WebSql in a new project, I have not yet made use of plugins cordova with quasar.
-
Ooh, be careful! Web SQL has been deprecated for a long time, and dropped by Firefox & Edge: http://caniuse.com/#feat=sql-storage
That stackoverflow article is pretty outdated, and IndexedDB is now supported by iOS: http://caniuse.com/#feat=indexeddb
FYI, this page is a great resource for articles, offline-storage standards and 3rd-party libraries: https://developers.google.com/web/fundamentals/instant-and-offline/web-storage/offline-for-pwa -
what is the best practice for using database other then firebase for mobile devices mainly ?
Thanks in advance -
@king_of_leon - Firebase isn’t a database for mobile devices per se, like what is discussed above (databases that work in the client’s own device). Firebase is a backend system, which a front-end app can connect to via a web api.
Scott