collection<T> method

CollectionQuery<T> collection<T>(
  1. String path, {
  2. CollectionQueryOptions<T> options = const CollectionQueryOptions(),
  3. bool tryUseAuth = true,
})

tryUseAuth will attach Authorization information to the Headers if possible

Implementation

CollectionQuery<T> collection<T>(String path, {CollectionQueryOptions<T> options = const CollectionQueryOptions(), bool tryUseAuth = true}) {
  return CollectionQuery<T>(
    baseUrl: baseUrl,
    path: path,
    options: options,
    cookie: tryUseAuth ? _cookie : null,
    bearer: tryUseAuth ? _bearer : null,
  );
}