# rowHeightFn

행 인덱스와 데이터를 받아 개별 행 높이를 계산합니다. 높이에 영향을 주는 데이터가 바뀌면 refreshRowHeights로 다시 계산합니다.

Canonical: https://grid.syidax.com/ko/docs/options/rowHeightFn/

<a id="meaning"></a>

## 무엇을 하는 API인가요

행 인덱스와 데이터를 받아 개별 행 높이를 계산합니다. 높이에 영향을 주는 데이터가 바뀌면 refreshRowHeights로 다시 계산합니다.

<a id="contract"></a>

## 입력과 결과의 정확한 타입

```typescript
rowHeightFn: (index: number, row: GridData) => number
```

| 항목 | 값 |
| --- | --- |
| JavaScript 이름 | rowHeightFn |
| HTML 속성 | row-height-fn |
| 기본값 | undefined |
| 입력 타입 | (index: number, row: GridData) => number |

<a id="usage"></a>

## 사용 흐름

이 항목은 Grid 요소의 프로퍼티에 설정합니다. 배열·객체·콜백 함수는 JavaScript로 전달하고, 변경을 반영할 때 새 배열이나 객체를 사용하세요.

<a id="types"></a>

## 관련 타입 읽기

- [GridData](https://grid.syidax.com/ko/docs/types/GridData.md)

<a id="recipes"></a>

## 기능별 설명과 예제

- [대량 데이터](https://grid.syidax.com/ko/docs/features/virtualization.md) — 가상화는 전체 데이터 중 화면 주변에 필요한 행·열 DOM만 렌더링합니다. 데이터 자체를 서버에서 일부만 가져오는 행 모델과는 다른 성능 기능입니다.
