React Native Expo config.ts
2 min readNov 14, 2019
Expo init
실행 시, option중에 managed 메뉴 중 기본 ts-config.json을 제공을 해주는 option이 있다.
해당 파일의 내용은 아래와 같다.
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
//default export가 없는 경우에도 default import를 가능하도록 허용. 해당 옵션은 코드 emit과는 관계가 없고, typechecking에만 적용됨.
// export class Foo { member: string; } 을 할시 (b.ts)
// export default { Foo } 가 기본으로 설정된다."jsx": "react-native",
"lib": ["dom", "esnext"],
"moduleResolution": "node",
"noEmit": true,
"skipLibCheck": true,
"resolveJsonModule": true *여기부터는 custom입니다.*
"allowJs": true // import "*.js"가능하게
"locale": "ko", // 에러메세지 출력 언어 설정
"noImplicitAny": false, // any타입 금지
"charset": "utf8", // 입력파일의 문자집합 형식
"exclude": ["node_modules"]
}