长文本 + 自适应行高 表格滚动性能优化
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 3.7k
- Forks
- 486
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 16
Description
长文本 + 自适应行高 表格快速滚动时卡顿
@visactor/vutils 中 textMeasure文件中
TextMeasure.NUMBERS_CHAR_SET.includes(char) 运行时间过长
建议使用 Set().has 替代 TextMeasure.NUMBERS_CHAR_SET.includes。
减少includes使用。
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the textMeasure file in @visactor/vutils and inspect the TextMeasure.NUMBERS_CHAR_SET.includes(char) call used during text measurement. Replace the slow character lookup as proposed, then verify that long-text tables with adaptive row heights remain responsive during fast scrolling.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- performance
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100