리μ‘νΈ μ±μ μ²μλΆν° λ§λ€κΈ° μν μ΅κ³ μ λ°©λ²!
λΌμ΄λΈλ¬λ¦¬ | λ²μ |
---|---|
react (with π£Hooks) | ^16.11 |
react-dom | ^16.11 |
react-router | ^5.1 |
react-scripts | 3.3 |
styled-components | ^4.4 |
typescript | 3.6 |
antd | 4.1.5 |
νμ΄ν μμ μ μν΄μλ index.htmlμμ νμ¬ React-TypeScript-Boilerplate
λ‘ λμ΄μλ λΆλΆλ€μ κ³ μ³μΌν©λλ€.
<meta
name="apple-mobile-web-app-title"
content="React-TypeScript-Boilerplate"
/>
<title>React-TypeScript-Boilerplate</title>
νλΉμ½ μμ μ μν΄μλ assetμ μλ κΈ°μ‘΄μ μ΄λ―Έμ§ νμΌλ€μ λ체ν΄μΌν©λλ€. (νμ¬λ π¦ μ΄λͺ¨μ§λ‘ λμ΄μμ΅λλ€.)
FAVIC-O-MATICμ μ μνμ¬ Every damm size,sir!
λ₯Ό μ ννκ³ Upload Your Image
λ²νΌμ ν΄λ¦νμ¬ νμν μ΄λ―Έμ§ νμΌμ΄ λ€μ΄μλ μμΆνμΌμ λ°μ΅λλ€.
{
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended",
"prettier/@typescript-eslint",
"plugin:prettier/recommended"
],
"plugins": ["react", "@typescript-eslint", "prettier"],
"env": {
"browser": true,
"jasmine": true,
"jest": true
},
"settings": {
"react": {
"pragma": "React",
"version": "detect"
}
},
"parser": "@typescript-eslint/parser"
}
tsconfig.json
μλ TypeScript
μ μ»΄νμΌλ¬ μ΅μ
μ΄ μ μλμ΄ μμ΅λλ€.
λ€μ 컀맨λλ₯Ό ν΅ν΄ κ°μ₯ κΈ°λ³Έμ μΈ tsconfig.json
λ₯Ό μμ±ν μ μμ΅λλ€.
$ npx tsc --init
ν΄λΉ νλ‘μ νΈμμλ κΈ°λ³Έ μ΅μ
μμ μμ λ tsconfig.json
λ₯Ό μ¬μ©ν©λλ€.
{
"compilerOptions": {
"target": "es5",
"lib": ["dom", "dom.iterable", "esnext"],
"noImplicitAny": false,
"allowJs": true,
"skipLibCheck": true,
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"strict": true,
"forceConsistentCasingInFileNames": true,
"module": "esnext",
"moduleResolution": "node",
"resolveJsonModule": true,
"isolatedModules": true,
"noEmit": true,
"jsx": "react"
},
"include": ["src"]
}
{
"defaultSeverity": "error",
"extends": ["tslint:recommended"],
"jsRules": {},
"rules": {
"quotemark": false,
"ordered-imports": false,
"object-literal-sort-keys": false,
"member-access": false
},
"rulesDirectory": []
}
{
"singleQuote": true,
"semi": true,
"useTabs": false,
"tabWidth": 2,
"trailingComma": "all",
"printWidth": 80,
"arrowParens": "always",
"orderedImports": true
}
$ npm install
$ npm run start
$ npm run build
MIT