하다보니 추가로 질문 하나 하겠슴미다
(숙제1) object 타입을 정의한 type alias 두개를 & 기호로 합칠 때 중복된 속성이 있으면 어떻게 될까요?
이걸로 요리조리 해보고 있는데
type AType = {name : string};
type BType = {name : number, age : number};
type Hypeboy = AType & BType;
let asdf :Hypeboy = {name : "애플맨", age : 60}
이렇게 치면 name 부분에서 에러 나면서 Type 'string' is not assignable to type 'never'.t(2322)
요렇게 나오고
Btype의 name을 boolean, null, undefined같은 걸로 정의하니까
이번엔 name과 age에서 둘 다 저 에러가 뜨네요.
요 never는 무엇인가요잉