Created
September 27, 2017 02:18
-
-
Save aytdm/ee7dad4bbf2978e1d38a082a05c1c9c6 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> | |
<el-menu theme="dark" :default-active="activeIndex" mode="horizontal" @select="handleSelect"> | |
<el-menu-item index="1">List of Posts</el-menu-item> | |
<el-submenu index="2"> | |
<template slot="title">Documentation</template> | |
<el-menu-item index="2-1"><a href="https://nuxtjs.org/guide" target="_blank">NUXT</a></el-menu-item> | |
<el-menu-item index="2-2"><a href="https://vuejs.org/v2/guide/" target="_blank">Vue.js</a></el-menu-item> | |
<el-menu-item index="2-3"><a href="http://element.eleme.io/#/en-US/component/installation" target="_blank">Element</a></el-menu-item> | |
</el-submenu> | |
<el-menu-item index="3"><nuxt-link to="/">Back Top</nuxt-link></el-menu-item> | |
</el-menu> | |
</div> | |
</template> | |
<script> | |
export default { | |
data () { | |
return { | |
activeIndex: '1', | |
activeIndex2: '1' | |
} | |
}, | |
methods: { | |
handleSelect (key, keyPath) { | |
console.log(key, keyPath) | |
} | |
} | |
} | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment