Created
March 25, 2021 15:53
-
-
Save bengrunfeld/f732b1014c265a28b024fbf431f54d29 to your computer and use it in GitHub Desktop.
CSS in JSX
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
// style.module.css | |
.pageWrapper { display: flex; } | |
.investorForm { width: 90%; } | |
.addInvestorBtn{ background: green; } | |
.clearFormBtn{ background: red; } | |
.nextPageBtn{ background: blue; } | |
// Page.jsx | |
import styles from './mystyle.module.css'; | |
const Page = () => ( | |
<div className={styles.pageWrapper> | |
<div className={styles.investorForm> | |
<input className={styles.investorInput} /> | |
<button className={styles.addInvestorBtn}>Add Investor</button> | |
</div> | |
<button className={styles.clearFormBtn}Clear form</button> | |
<button className={styles.nextPageBtn}Next</button> | |
</div> | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment