Function.csvSourceStructure
function csvSourceStructure(headers: readonly (string | null | undefined)[]):
| {
columns: string[];
format: "csv";
}
| {
format: "json";
paths: string[];
}
| null;
Canonical structure of a CSV header row, or null when the row cannot identify a structure (no columns, or any header empty/unusable once normalized — typically a headerless file).
Parameters
| Parameter | Type |
|---|---|
headers | readonly (string |
Returns
| {
columns: string[];
format: "csv";
}
| {
format: "json";
paths: string[];
}
| null