v-model 디렉티브를 사용하여 input, textarea, select 요소들에 양방향 데이터 바인딩을 생성할 수 있다.
<input type="text" :value="msg" @input="msg = $event.target.value" />
위 아래 코드 같다.
:value속성과 @input이벤트를 v-model로 단축하여 사용가능
하지만 위의 코드는 한글 입력 시 사용 ❕
<input type="text" v-model="msg" />
컴포넌트를 사용할 때
props 사용$emit 사용$emit 메소드는 이벤트를 커스텀하여 이름을 넘김