Skip to content

Commit

Permalink
Merge pull request #64 from eyra/consent-form-lag-fx
Browse files Browse the repository at this point in the history
fix from Kasper, determine rowcount once, prevents sudden slow downs …
  • Loading branch information
trbKnl authored Nov 23, 2023
2 parents 9d67d73 + e0b6269 commit 41765bf
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,8 @@ export const ConsentForm = (props: Props): JSX.Element => {

function rows (data: any): PropsUITableRow[] {
const result: PropsUITableRow[] = []
for (let row = 0; row <= rowCount(data); row++) {
const nRows = rowCount(data)
for (let row = 0; row <= nRows; row++) {
const id = `${row}`
const cells = columnNames(data).map((column: string) => rowCell(data, column, row))
result.push({ __type__: 'PropsUITableRow', id, cells })
Expand Down

0 comments on commit 41765bf

Please sign in to comment.