import { isArray, isEmpty } from "remeda";
import { isVTable } from "../chatType.js";
const checkVSeed = (vseed)=>{
    const { chartType, dataset, dimensions, measures } = vseed;
    if (!chartType) throw new Error('chartType is required');
    if (!dataset || !isArray(dataset)) throw new Error('dataset is required, and must be an array');
    if (isEmpty(dataset) && !isVTable(vseed)) throw new Error('dataset can not empty');
    if (dimensions && !Array.isArray(dimensions)) throw new Error('dimensions must be an array');
    if (measures && !Array.isArray(measures)) throw new Error('measures must be an array');
};
export { checkVSeed };

//# sourceMappingURL=checkVSeed.js.map