aksonov / aksonov/react-native-svg-elements
changing the fill through a prop only works once
- 主要語言
- Objective-C
- 星號
- 40
- 分支
- 2
- PR 合併指標
- 30 天內沒有已合併 PR
描述
Hi,
I have an SVG I created and it receives the 'fill' and 'stroke' as props. When I initially render the SVG it works fine. However, once the prop changes, the color doesn't change (even though the component did re-render itself).
This is the component:
``` coffeescript
'use strict'
React = require('react-native')
{ Svg, G, Path } = require('react-native-svg-elements')
NotificationsIcon = React.createClass
render: ->
module.exports = NotificationsIcon
```
And I call it like this:
``` coffeescript
iconColor: -> if @props.selected then colors.actionBlue else colors.baseWhite
```
I am seeing the exact same behaviour with other icons. Any ideas?
Thanks!
貢獻指南
這個儲存庫沒有索引到貢獻指南
評估
這個 Issue 還沒有評估資料。