Created
June 30, 2020 05:44
-
-
Save liaooliver/6ef5bd6a059bb298ac49a3918ae13229 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<div id="app"> | |
// 建立一個按鈕,綁定 testGetVuex 事件 | |
<button @click="testGetVuex()">測試 取得 Vuex 實體</button> | |
</div> | |
</template> | |
<script> | |
export default { | |
name: "App", | |
methods: { | |
testGetVuex() { | |
// 透過 testGetVuex 事件 來呼叫 Vuex | |
console.log(this.$store); | |
} | |
} | |
}; | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment