Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

186
Views
Confused by angular firestore possibilities

Can someone please enlighten me as I can't get the grasp on what this is all about using Angular and Firestore.

Started using Google Firebase and tried to implement CRUD using Firestore.

What is the difference between this library.

import { Firestore } from '@angular/fire/firestore'
...
this.coll = collection(this.firestore, 'user-services');

collectionData(this.coll, {
    idField: 'id'
  }).pipe(shareReplay({ bufferSize: 1, refCount: true }))...

And the other firestore library used in the git repository in the documentation.. (https://github.com/angular/angularfire/blob/bea9d6774ce455d50363f9844ea48c32d6c37eb6/docs/firestore/collections.md)

import { AngularFirestore, AngularFirestoreDocument } from '@angular/fire/compat/firestore';

I think this is really weird that there is no straight line on which to use, if I try to use them both the first one stops working..

Can someone explain to me what's happening under the hood or provide some history / usage guide which one is newest / safest to use?

Kind regards!

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

They changed a lot in version 9 so they provided a compatibility layer "@angular/fire/compat/firestore" to allow a smoother migration coming from firebase 8.

The import "@angular/fire/firestore" is the new tree shakeable version for a smaller bundle size.

In your case if it's brand new project you should not use the compatibility layer.

You can read more here https://firebase.google.com/docs/web/modular-upgrade

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!