Comento | Week 2. TypeScript & Clean Code
6322 ワード
Week 2: TypeScript & Clean Code
ガイダンス
1. JS to TS
1.1 JSの短い歴史
1.2タイプのスクリプトの利点
コンパイル時に
2.基本文法
2.1 any
2.2 null and undefined
2.3関数
2.4 interface
2.5 interface vs type
2.6 enum vs union
2.7 mini practice
// Me
export type ClassStatus = "모집전" | "모집중" | "모집완료";
export interface CommonCamp {
title: string;
startDate: Date; //string?
}
export interface HotCamp extends CommonCamp {
status: ClassStatus;
}
export interface SaleCamp extends CommonCamp {
job: string;
field: string;
}
// Mentor
// TODO: 실제 프로젝트보고 수정할수도 있음
export interface Camp {
id: number;
type: "popular" | "discount";
status: ClassStatus;
category?: string;
skill?: string;
campName: string;
thumbnail: string;
dateStart: string;
}
3. Think about Type
4.コードの作成+コラボレーションしやすいコード
4.1基本
4.2コメント
4.3コード複雑度管理
4.4コード品質管理
4.5童子軍ルール
Reference
この問題について(Comento | Week 2. TypeScript & Clean Code), 我々は、より多くの情報をここで見つけました https://velog.io/@leebonggu12/Comento-Week-2.-TypeScript-Clean-Codeテキストは自由に共有またはコピーできます。ただし、このドキュメントのURLは参考URLとして残しておいてください。
Collection and Share based on the CC Protocol