-
-
Save alexesDev/3fe1ff7e67a0a7135c74ba673084551e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const FlatIcon = ({ iconName }) => ( | |
<i className={`faticon-${iconName}`} /> | |
) | |
FlatIcon.propTypes = { | |
iconName: React.PropTypes.string.isRequired, | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var FlatIcon = React.createClass({ | |
displayName: "FlatIcon", | |
propTypes: { | |
iconName: React.PropTypes.string.isRequired | |
}, | |
render: function() { | |
return React.createElement("i", { | |
"className": "flaticon-" + this.props.iconName | |
}); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment