private getComputedOptions()

in src/tableView.ts [284:304]


    private getComputedOptions(data: any[]): TableViewComputedOptions {
        let rows: number,
            columns: number = 0;

        rows = data
            ? data.length
            : 0;

        for (let i: number = 0; i < rows; i++) {
            let currentRow: any[] = data[i];

            if (currentRow && currentRow.length > columns) {
                columns = currentRow.length;
            }
        }

        return {
            columns: columns,
            rows: rows
        };
    }