-
Notifications
You must be signed in to change notification settings - Fork 11
프로젝트 설정
ParkSeungHwan edited this page Nov 25, 2020
·
1 revision
npm i -g create-react-app
create-react-app [app name] -template typescript
- dependencies
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: [
'plugin:react/recommended',
'airbnb',
'plugin:prettier/recommended',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaFeatures: {
tsx: true,
},
ecmaVersion: 2020,
sourceType: 'module',
},
settings: {
'import/resolver': {
node: {
extensions: ['.js', '.jsx', '.ts', '.tsx'],
},
},
},
plugins: ['react', '@typescript-eslint'],
rules: {
'react/jsx-filename-extension': [
1,
{ extensions: ['.js', '.jsx', '.ts', '.tsx'] },
],
'import/extensions': [
'error',
'ignorePackages',
{
js: 'never',
jsx: 'never',
ts: 'never',
tsx: 'never',
},
],
},
};
https://create-react-app.dev/docs/adding-typescript/
- dependencies
npm i --save-dev ts-loader typescript webpack nodemon ts-node webpack-cli
npm i --save koa @types/koa
tsc --init
const path = require('path');
module.exports = {
name: 'ts-back-setting', mode: 'development', // "production" | "development" | "none"
devtool: 'eval', // source-map hidden-source-map
resolve: {
modules: ['node_modules'],
extensions: ['.ts', 'json', '.jsx', '.js'],
alias: {
"@Controller": path.resolve(__dirname, 'src/controller'),
"@Router": path.resolve(__dirname, 'src/router'),
"@Api": path.resolve(__dirname, 'src/api'),
},
},
entry: {
index: ['./app.ts']
},
module: {
rules: [
{
test: /\.ts$/,
use: ['ts-loader'],
exclude: ["/node_modules"]
},
]
},
optimization: {},
output: {
path: path.join(__dirname, './dist'),
filename: '[name].js'
},
target: 'node',
}
import Koa from 'koa';
const app = new Koa();
app.use((ctx: Koa.Context) => { ctx.body = 'hello, Koa!'; });
app.listen(4000, () => { console.log('Listening to port 4000'); });
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: ['airbnb-base', 'plugin:prettier/recommended'],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 12,
sourceType: 'module',
},
plugins: ['@typescript-eslint'],
rules: {},
};
{
"printWidth": 80,
"tabWidth": 2,
"singleQuote": true,
"trailingComma": "all",
"bracketSpacing": true,
"semi": true,
"useTabs": false,
"overrides": [
{
"files": "*.md",
"options": {
"tabWidth": 4
}
}
]
}
{
"editor.defaultFormatter": "dbaeumer.vscode-eslint",
"editor.formatOnSave": true,
"eslint.format.enable": true,
"eslint.alwaysShowStatus": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"eslint.validate": ["javascript"],
"javascript.format.enable": false,
}
- Optimistic Update
- 상태관리를 어떻게 할까
- Atomic Design 설계
- Mongoose Atomic Update 방식을 찾아서
- MobX Best Practices는 어디에
- 거래내역 스토어 관리
- user-account DB관계 수정
- 알림 기능 구현
1 주차
- 데일리스크럼
- 회고