TypeScript Version: 2.2.2
Code
In React:
Property 'href' does not exist on type 'SVGProps<SVGUseElement>'.
Expected behavior:
The MDN SVGUseElement does not include the href property but I believe it is required to actually 'use' it. If you look here xlink:href was used in the example. However, that has now been deprecated in SVG 2 to drop the xlink namespace, see here.
Actual behavior:
Allow href property
Where is SVGProps defined?
This comes from a definition file
https://github.com/DefinitelyTyped/DefinitelyTyped/blob/354cec620daccfa0ad167ba046651fb5fef69e8a/types/react/index.d.ts
React does not list href as a supported SVG property.
https://facebook.github.io/react/docs/dom-elements.html
See also
http://stackoverflow.com/questions/26815738/svg-use-tag-and-reactjs
It looks like you want xlinkHref instead
Most helpful comment
This comes from a definition file
https://github.com/DefinitelyTyped/DefinitelyTyped/blob/354cec620daccfa0ad167ba046651fb5fef69e8a/types/react/index.d.ts
React does not list
hrefas a supported SVG property.https://facebook.github.io/react/docs/dom-elements.html
See also
http://stackoverflow.com/questions/26815738/svg-use-tag-and-reactjs
It looks like you want
xlinkHrefinstead