<SearchBar
containerStyle= {{backgroundColor: '#fff',borderWidth: 1}}
inputContainerStyle= {{backgroundColor: '#fff'}}
searchIcon={{ size: 24,name: this.state.searchIconName }}
onChangeText={text => this.SearchFilterFunction(text)}
onClear={text => this.SearchFilterFunction('')}
placeholder="Type Here..."
value={this.state.search}
/>
<FlatList
data={this.state.dataSource}
ItemSeparatorComponent={this.ListViewItemSeparator}
renderItem={({ item }) => (
<Text style={styles.textStyle}>{item.title}</Text>
)}
enableEmptySections={true}
style={{ marginTop: 10 }}
keyExtractor={(item, index) => index.toString()}
/>
我想在更改时替换searchIcon。
在 searchIcon = {{size:24}} 中 enter image description he[enter image description here] 1 re