forked from codesquad-members-2022/airbnb
-
Notifications
You must be signed in to change notification settings - Fork 1
코드 컨벤션
YUNHO edited this page Jun 12, 2022
·
3 revisions
변수, 함수 : camelCase
컴포넌트 : PascalCase
상수 : UPPERCASE_SNAKE_CASE
폴더 : kebab-case
컴포넌트는 함수 선언문
으로 사용
컴포넌트 내부 함수나 기타 함수들은 표현식
으로 사용
스타일 컴포넌트는 S.
로 구분
import * as S from "./style";
export default function Component(){
const getSomething = () => {};
return (
<S.Container>
<div />
</S.Container>
)
}
const shortFunction = () => {
/* ... */
}