Firestore trigger not working when run in emulator
Solution 1:
It looks like my comment was helpful, posting it as an answer for visibility.
A new collection is automatically created when you create a new document using the set()
method.
There is no separate method for creating collections. Try adding a document as described in the docs. For example,
await db.collection('logging').doc('journal').set(data);