PouchDB vs Firebase vs SQLite in ionic 2

Hi, I’m new to ionic 2 and currently doing my undergraduate project which I got a limited time to learn. Could you suggest the database that is easy to learn and to be implement in my project. Thanks

At beginner’s level SQLite is easy to implement

1 Like

Depending on the browser support that you need, it’s much faster to use the built-in storage functions, as they don’t have the Cordova round trip overhead from using native plugins. If you want SQL, then Web SQL (which is SQLite under the hood) may be deprecated but it’s still available on iOS and Android: http://caniuse.com/sql-storage/embed

1 Like

I’m in the exact same position as you, doing my undergraduate project and I also have no previous experience using Javascript in any way, and brand new to Ionic.

I have used Firebase, due to the need for log in functionality and it only took a couple of hours to get it working. If its any help, I used this tutorial to get started (although it is quite limited), and then used his GitHub project to guide me the rest of the way which is here.

As long as you use that tutorial for the initial tutorial to get you going you should be fine if you take a look through the providers and how they work with the rest of the project.

I was impressed by what Firebase offered, although it was the first time I’d used anything like it before which may be why!

As @abhisheklamrood said, SQLite is very easy to implement also. I found this SQLite tutorial very easy to follow and I used this as a placeholder while I tested other parts of the app.

Good luck!

Edit: Purely because I have had to consider this for my project, it may be worth avoiding Web SQL for when you justify technologies used, because if Web SQL is depreciated as mentioned earlier, you can argue that it is not a future proof solution. I have never used it so I couldn’t comment on how good it is.

2 Likes

Thanks jake_b for the very detail explanation. At first, actually I also want to use Firebase too because the online class I took in Udemy used Firebase but my friend said it is a bit complicated. Maybe I should try both Firebase and SQLite. Thanks again and I hope that you also doing good in your project!

Have a look over the Firebase links in my post, they make it very easy! And they demonstrate the use of NgZones which prevent the user from navigating around the app unless they are signed in.

Firebase is a little more advanced that SQLite but the ability to store the data remotely was essential in my case, and it also happened to make adding an option to reset password, change email, etc a breeze and I would say the little extra effort required to implement it pays off. Especially with its offline capabilities which I plan on implementing this weekend.

1 Like

I’ve been trying Firebase thanks to your advice which the Firebase is actually pretty interesting for me. I just successfully run my simple apps which connected to the Firebase. Thanks @jake_b for encouraging me to use Firebase.

1 Like