The second parameter, createElement is an attribute hash, where key is the attribute name and value is the attribute value. The style attribute accepts hash values ββfor style names. So for example:
React.createElement("p", {style: {color: "red", backgroundColor: "blue"}}, this.props.paragraph)
source share