3 ms·
Firebase has some strengths, but I profoundly dislike its NoSQL databases. I started learning web dev ~6 years ago with non-relational dbs but now I'm in the ca
by arcturus17 5y ago
Firebase has some strengths, but I profoundly dislike its NoSQL databases. I started learning web dev ~6 years ago with non-relational dbs but now I'm in the camp that 98% of new projects should start with a relational db. Eager to try Supabase on my next project.
- picardo 5y agoNoSQL was overhyped. SQL is awesome.
- digianarchist 5y agoThe main problem with Firebase is the lack of search capabilities which is ironic considering Google is the parent company. The fact that they haven't shipped this is probably down to backing themselves into a corner with the DB architecture they've chosen. And still point customers to a competitors... https://firebase.google.com/docs/firestore/solutions/search https://firebase.google.com/docs/firestore/solutions/search
- simonbarker87 5y agoAhhhhh! I had to make partial search indexes for anything I wanted to be searchable as the user typed, so infuriating and unbelievable
- MarcelOlsz 5y agoOh god. I'm dealing with this now. Whole project on firebase. Implementing my final feature before launch (full text search). Any last words of wisdom before I drop off the face of the earth for a month trying to get this working?
- simonbarker87 5y agoSo I wrote a little function that iterates over the searchable text (in this case it was full names and user names) and adds each fragment/token to a collection and then did a match on that collection in the query. Anything the user might type to find the thing has to go in that child object so you have to tokenise to give yourself every version of what they will be searching as they type. So my name would go in as S Si Sim Simo Simon Simonb Simonbar Simonbark Simonbarke Simonbarker B Ba Bar Bark Barke Barker Etc Etc Failing that just dump everything in to an elastic search instance and call out to that for search. It’s not too hard to keep and ES in sync but it’s also more expensive sadly
- MarcelOlsz 5y agoGreat thank you!