module.css

import styles from './Button.**module.css**'

const Button = props => <button className={**styles['button']**} />

export default Button

classNames

classNames('foo', 'bar')

classNames({foo: true}, {bar: false})  // foo 만 나옴

classNames(styles['button'], styles['loading'])

// classNames와 styles 결합하기
const cx = **classNames.bind(styles)**
cx('button', 'loading')  // classNames(styles['button'], styles['loading']) 와 같음

styled-components

import styled, { css } from 'styled-components'

const StyledButton = **styled**.button`  // 백틱 기호 써야함
background: transparent;
border-radius: 3px;
border: 2px solid royalblue;

${props => props.primary &&  // 물려 받는 속성이 있는 경우
css`
background: royalblue;
color: white;

:hover {
	border 2px solid red;
}
`}

export StyledButton

GlobalStyle

import { createGlobalStyle } from 'styled-components'

const GlobalStyle = createGlobalStyle`
button {
	color: yellow;
}
`
function App() {
	return (
		<GlobalStyle />
	)
}