使用实例方法绘制的虚线,在iOS上正常显示,在Android上显示为实线。
rzrobert opened this issue · comments
createDashedView() {
const path = new Path()
.moveTo(1, 1)
.lineTo(WINDOW_WIDTH, 1);
return (
<View style={{ backgroundColor: '#ffffff' }}>
<Shape d={path} stroke={CASHIER_GRAY_COLOR} strokeWidth={1} strokeDash={[1, 5]} />
);
}
162: FLog.w(ReactConstants.TAG, "ART: Dashes are not supported yet!");
Android 并不支持虚线的绘制
好的,谢谢。另外想请教一下,react-native-svg也不能在Android上绘制虚线是吗?
不确定,如果仅仅是绘制虚线的话建议用拼图的方式。