score:1

Accepted answer
 documentName.firestore().collection("collectionName").doc(yourDoc).get().then(queryResult =>{

      //Here create new array and push your data to array after making it unique 
      //using set or any other function

  });

score:0

let clearDocs = [...new Set(docs)];

score:1

const docs = [ {tag: 'test'},
              {tag: 'test1'},
              {tag: 'test2'},
              {tag: 'test2'},
              {tag: 'test2'}
             ];

const unique = [...new Set(docs.map(({tag})=> tag))];
console.log(unique);

Related Query

More Query from same tag