[Select] 不传 dataSource 会直接报错
Open
- Dominant language
- TypeScript
- Stars
- 128
- Forks
- 19
- PR merge metrics
- No merged PRs in 30d
Description
### 目前的问题
```jsx
```
提示:TypeError: Cannot read properties of undefined (reading 'map')
### 期望的结果
不报错,渲染一个空的下拉菜单,或填充一个 “无选项” 的 placeholder
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the issue with the Select.Single entry point and no dataSource, confirming the undefined.map error. Trace the Select implementation to find where dataSource is mapped, then verify that rendering without it produces an empty menu or the requested no-options placeholder without throwing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100