Created
November 9, 2017 21:47
-
-
Save indreklasn/14b38638841f6c0539127ad52358d099 to your computer and use it in GitHub Desktop.
Radium
This file contains hidden or 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
import React, { Component } from 'react'; | |
import Radium from 'radium'; | |
@Radium // decorator | |
class App extends Component { | |
render() { | |
const styles = { | |
wrapper: { | |
background: 'blue', | |
} | |
title: { | |
color: 'white' | |
} | |
}; | |
return ( | |
<div style={styles.wrapper}> | |
<h1 style={styles.title}>Hello Radium!</h1> | |
</div> | |
); | |
} | |
} | |
export default Radium(App); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment