In Meteor 2, I can pass document ids to Mongo functions, like find
, directly, without specifying a full selector
const result = Collection.find(
{ _id: documentId }, // this is valid
);
const result = Collection.find(documentId); // This is also valid and gets me the same result
This is specified in Meteor 2ās documentation:
However, this is not 100% clear in Meteor 3ās documentation:
The parameter naming makes it look like Meteor 3 will only support full selectors, and will not support strings by themselves, but this is not explicitly written, so Iām not sure what to expect.
Will Meteor 3ās Mongo functions still support strings and Object IDs as input for the first parameter, or will they only support Mongo selectors now? Also, will it still be supported in the future?
Thanks!