@ -2,8 +2,7 @@
id: inline-styles-tip
title: Inline Styles
layout: docs
permalink: inline-styles.html
script: "cookbook/inline-styles.js"
permalink: inline-styles-tip.html
---
In React, inline styles are not specified as a string, but as an object whose key is the camelCased version of the style name, and whose value is the style's value in string:
@ -3,7 +3,6 @@ id: inline-styles
### Problem
id: if-else-in-JSX-tip
title: If-Else in JSX
permalink: if-else-in-JSX-tip.html
`if-else` statements don't work inside JSX, since JSX is really just sugar for functions:
id: if-else-in-JSX
permalink: if-else-in-JSX.html
@ -1,9 +1,8 @@
id: self-closing-tag
id: self-closing-tag-tip
title: Self-Closing Tag
permalink: self-closing-tag-tip.html
In JSX, `<MyComponent />` alone is valid while `<MyComponent>` isn't.
permalink: self-closing-tag.html