export function assertCrudResourceDefinition(definition) {
    if (!definition.resourceId.trim())
        throw new Error('resourceId is required');
    const fields = new Set(definition.columns.map(x => x.field));
    for (const sensitive of definition.sensitiveFields)
        if (!fields.has(sensitive))
            throw new Error(`Sensitive field '${sensitive}' has no grid column contract`);
}
