Function defineDataset
-
defineDataset<Row extends Plain = Plain>(
name: string,
declaration: DatasetDeclaration<Row>,
options?: DefineDatasetOptions,
): Dataset<Row>Type Parameters
Parameters
- name: string
- declaration: DatasetDeclaration<Row>
- options: DefineDatasetOptions = {}
Returns Dataset<Row>
Declares a dataset. Validates the name, the scope and the limits and returns the declaration with the name attached. Throws
bad-datasetfor a principal scope unlessoptions.principalDatasetsis true, and for a principal dataset without a positivemaxStaleMsor withprovision: 'auto'.