The same image is provided by the library when you change only the color property. This is because color is incorrectly not part of the == (equals) method of SvgImageKey.
This leads to bugs such as the provider not providing an updated image when your theme updates (such as when enabling dark/light mode) and your image only changes the svg's applied color. For example:
The same image is provided by the library when you change only the
color
property. This is becausecolor
is incorrectly not part of the==
(equals) method ofSvgImageKey
.https://github.com/yang-f/flutter_svg_provider/blob/fd32f3c80c7756a8a26520f063ae54f4139c3dc2/lib/flutter_svg_provider.dart#L188
This leads to bugs such as the provider not providing an updated image when your theme updates (such as when enabling dark/light mode) and your image only changes the svg's applied color. For example: