--- /dev/null
+<script setup lang="ts">
+</script>
+
+<template>
+ <div class="container">
+ <div class="inside">
+ <a href="https://www.vuemastery.com/vue-router?coupon=ROUTER-DOCS&via=eduardo" target="_blank">
+ <span class="logo-wrapper">
+ <img alt="Vue Mastery Logo" width="25px" src="https://firebasestorage.googleapis.com/v0/b/vue-mastery.appspot.com/o/flamelink%2Fmedia%2Fvue-mastery-logo-small.png?alt=media&token=941fcc3a-2b6f-40e9-b4c8-56b3890da108">
+ </span>
+ <span class="description">
+ Get the <span class="highlight">Vue Router Cheat Sheet</span> from Vue Mastery
+ </span>
+ </a>
+ </div>
+ </div>
+</template>
+
+<style scoped>
+
+.container {
+ text-align: center;
+ margin-top: -30px;
+}
+
+.inside {
+ width:960px;
+ border-bottom: 1px solid var(--c-divider);
+ padding-bottom:50px;
+ margin: 0 auto;
+}
+
+a {
+ background-color: rgba(27,31,35,0.05);
+ border-radius: 8px;
+ padding: 8px 16px 8px 8px;
+}
+
+.description {
+ font-weight: 500;
+ font-size: 14px;
+ line-height: 20px;
+ color: #2c3e50;
+ margin-left:10px;
+ transition: color 0.5s;
+}
+
+a:hover {
+ text-decoration: none !important;
+}
+
+.description .highlight {
+ color: #3eaf7c;
+}
+
+@media (max-width: 960px) {
+ .inside {
+ width:100%;
+ }
+}
+
+@media (max-width: 420px) {
+ a {
+ display:block;
+ margin-left: 10px;
+ margin-right: 10px;
+ }
+}
+</style>
\ No newline at end of file
--- /dev/null
+<template>
+ <a href="https://www.vuemastery.com/vue-router?coupon=ROUTER-DOCS&via=eduardo" target="_blank">
+ <span class="logo-wrapper">
+ <img alt="Vue Mastery Logo" width="25px" src="https://firebasestorage.googleapis.com/v0/b/vue-mastery.appspot.com/o/flamelink%2Fmedia%2Fvue-mastery-logo-small.png?alt=media&token=941fcc3a-2b6f-40e9-b4c8-56b3890da108">
+ </span>
+ <span class="description">
+ Get the <span>Vue Router Cheat Sheet</span> from Vue Mastery
+ </span>
+ </a>
+</template>
+
+<style scoped>
+a {
+ background-color: rgba(27,31,35,0.05);
+ border-radius: 8px;
+ padding: 8px 16px 8px 8px;
+ transition: color 0.5s, background-color 0.5s;
+ display: flex;
+ align-items: center;
+ margin-top:10px;
+ margin-bottom:10px;
+}
+
+.description {
+ flex: 1;
+ font-weight: 500;
+ font-size: 14px;
+ line-height: 20px;
+ color: #2c3e50;
+ margin: 0 0 0 16px;
+ transition: color 0.5s;
+}
+
+a:hover {
+ text-decoration: none !important;
+}
+
+.description span {
+ color: #3eaf7c;
+}
+
+.logo-wrapper {
+ position: relative;
+ width: 48px;
+ height: 48px;
+ border-radius: 50%;
+ background-color: white;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+}
+
+.logo-wrapper img {
+ width: 25px;
+ object-fit: contain;
+}
+
+@media (max-width: 576px) {
+
+ .description {
+ font-size: 12px;
+ line-height: 18px;
+ }
+ .logo-wrapper {
+ position: relative;
+ width: 32px;
+ height: 32px;
+ }
+}
+</style>
\ No newline at end of file
<div class="main-container">
<BannerTop />
<ParentLayout>
+ <template #home-hero>
+ <VueMasteryHomeLink></VueMasteryHomeLink>
+ </template>
<template #sidebar-top>
<div class="sponsors sponsors-top">
<span>Platinum Sponsors</span>
<script>
import { defineAsyncComponent } from 'vue'
import DefaultTheme from 'vitepress/dist/client/theme-default'
+import VueMasteryHomeLink from '../components/VueMasteryHomeLink.vue'
import sponsors from '../components/sponsors.json'
import './banner-top.css'
name: 'Layout',
components: {
ParentLayout: DefaultTheme.Layout,
- BannerTop
+ BannerTop,
+ VueMasteryHomeLink
},
data() {
return {
import Layout from './Layout.vue'
import './sponsors.css'
import VueSchoolLink from '../components/VueSchoolLink.vue'
+import VueMasteryLogoLink from '../components/VueMasteryLogoLink.vue'
export default {
...DefaultTheme,
Layout,
enhanceApp({ app, router, siteData }) {
app.component('VueSchoolLink', VueSchoolLink)
+ app.component('VueMasteryLogoLink', VueMasteryLogoLink)
// app is the Vue 3 app instance from createApp()
// router is VitePress' custom router (see `lib/app/router.js`)
// siteData is a ref of current site-level metadata.
`router-view` will display the component that corresponds to the url. You can put it anywhere to adapt it to your layout.
+<VueMasteryLogoLink></VueMasteryLogoLink>
+
## JavaScript
```js
# Installation
+<VueMasteryLogoLink></VueMasteryLogoLink>
+
## Direct Download / CDN
[https://unpkg.com/vue-router@4](https://unpkg.com/vue-router@4)