1.methods:
監聽click事件
methods:{
clickFunction:function(){
}
}
2.mounted:
頁面初始化方法
mounted(){
}
執行順序是子組件---父組件
3.props:
接收來自父組件的數據
props: {
seller: {
type: Object
}
}
4.$emit 向父組件傳值
this.$emit('showCityName',data);
觸發父組件的showCItyName事件。