antonreshetov / vue-unicons

1000+ Pixel-perfect svg icons for your next project as Vue components
https://antonreshetov.github.io/vue-unicons/
MIT License
1k stars 56 forks source link

Can't change prop fill after icon mounted. #47

Closed leyenda closed 3 years ago

leyenda commented 3 years ago

Hello everyone,

The prop fill is assigned to a data variable called localFill, only when the component is being created.

data () {
    return {
      localFill: this.fill
    }
  }

That makes not posible to change the fill prop once the icon is mounted. You can see in this example.

Maybe setting a watcher on the prop fill that update localFill is the fix?

antonreshetov commented 3 years ago

Closed because it was fixed in #48

leyenda commented 3 years ago

Thank you for the fix, may I ask if it can be released?

Edited: I am sorry, didnt see it was released.