mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
9 lines
220 B
TypeScript
9 lines
220 B
TypeScript
import { toDataFrame, DataFrameDTO, toCSV } from '@grafana/data';
|
|
|
|
export function dataFrameToCSV(dto?: DataFrameDTO[]) {
|
|
if (!dto || !dto.length) {
|
|
return '';
|
|
}
|
|
return toCSV(dto.map(v => toDataFrame(dto)));
|
|
}
|