Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

自定义多个marker时,部分渲染不出来 #138

Closed
jnzw1986 opened this issue Dec 23, 2017 · 12 comments
Closed

自定义多个marker时,部分渲染不出来 #138

jnzw1986 opened this issue Dec 23, 2017 · 12 comments
Labels
bug Something isn't working ios Only for iOS

Comments

@jnzw1986
Copy link

<Marker
key = {index}
icon={() =>

{dataItem.name}
{dataItem.desc}

}
coordinate={location}
onPress={() => this._onMarkerViewPress(dataItem.latitude, dataItem.longitude)}
clickable = {this.state.markerType == 3?false:true}
infoWindowEnabled = {false}
draggable = {true}
flat = {true}
/>

@qiuxiang
Copy link
Owner

要看你的 icon 里面是怎么写的

@jnzw1986
Copy link
Author

v0.8.0还没有这个问题。更新到0.8.1出现概率性自定义marker不生效,应该显示自定义marker的地方依然显示红色锚点。

@jnzw1986
Copy link
Author

<Marker
key = {index}
icon={() =>

{dataItem.name}
{dataItem.desc}

}
coordinate={location}
onPress={() => this._onMarkerViewPress(dataItem.latitude, dataItem.longitude)}
clickable = {this.state.markerType == 3?false:true}
infoWindowEnabled = {false}
draggable = {true}
flat = {true}
/>

@jnzw1986
Copy link
Author

icon={() =>

{dataItem.name}
{dataItem.desc}

}

@jnzw1986
Copy link
Author

icon={() => <View style={markerStyle}> <Text style={styles.markerText}>{dataItem.name}</Text> <Text style={styles.markerText}>{dataItem.desc}</Text> </View> }

@qiuxiang
Copy link
Owner

ios?android?红色锚点是什么,有截图?

@qiuxiang
Copy link
Owner

最好提供完整的,可以重现的,整个 screen 的代码

@jnzw1986
Copy link
Author

App-map-demo.js.zip

@qiuxiang
Copy link
Owner

ios?android?如果不用 icon,问题是不是还会出现?

@jnzw1986
Copy link
Author

ios。不用icon怎么实现自定义marker?

@jnzw1986
Copy link
Author

123456

@qiuxiang qiuxiang added bug Something isn't working ios Only for iOS labels Dec 23, 2017
@qiuxiang
Copy link
Owner

发布了一个新版本

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working ios Only for iOS
Projects
None yet
Development

No branches or pull requests

2 participants