Closed amsardesai closed 9 years ago
Merged, thanks @amsardesai!
There's just one drawback: now it is not possible to do this:
import fa from 'react-fontawesome'
...
<fa name="mobile" />
...
With a fixed displayName
, we have to do this
import FontAwesome from 'react-fontawesome'
...
<FontAwesome name="mobile" />
...
@rafael84 I don't think it is possible to do specifically that since react components must start with a capital letter, unless they're the property of some object. This rule is enforced in the JSX transformer. More info: http://stackoverflow.com/questions/30373343/reactjs-component-names-must-begin-with-capital-letters
Otherwise, if you did the following:
import Fa from 'react-fontawesome'
...
<Fa name="mobile" />
...
It should work.
Sometimes when I'm debugging using React Dev Tools, this component shows up as "Unknown Component". This simple change will make it say "FontAwesome" instead.