mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-18 03:35:17 +00:00
b1b9e0bcbc
* support named views for extendRoutes config * fix lint errors * fix lint errors 2 * some refactoring * var rename * fixture & unit tests * fix: style * nuxt-child named view example and test * nuxt element with named view in layout * lint
25 lines
295 B
Vue
25 lines
295 B
Vue
<template>
|
|
<div>
|
|
<h2>Child content</h2>
|
|
ID:{{ id }}
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: 'Child',
|
|
validate({ params }) {
|
|
return !isNaN(+params.id)
|
|
},
|
|
computed: {
|
|
id() {
|
|
return this.$route.params.id
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped>
|
|
|
|
</style>
|