Collection
Collections are analagous to GlobalDataStore.
Functions
load
Loads the document with key, migrates it, and session locks it.
If specified, the document's DataStoreKeyInfo:GetUserIds() will be set to defaultUserIds if the document has
never been loaded.
read
Collection:read(key: string) → Promise<T?>
Reads the data of the document with key regardless of whether it is session locked. This is useful for viewing a
document without editing or session locking it. The data gets migrated but not saved.
If the document has never been loaded, the promise will return nil.
DataStoreGetOptions.UseCache is disabled.
remove
Collection:remove(key: string) → Promise<()>Removes the data of the document with key.
If a document is open while remove is called, the open document will fail to save/close and the data will still be removed.