alibaba / alibaba/rex-design

[Select] 不传 dataSource 会直接报错

Open
#9 0 comments 0 reactions 0 assignees View on GitHub
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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.