blob: f2bef7433908da4ac9135d604f65de0a845081c5 (
plain) (
tree)
|
|
<template>
<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
<div class="container">
<router-link class="navbar-brand" to="/">MEVN Shop</router-link>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav me-auto mb-2 mb-lg-0">
<li class="nav-item">
<router-link class="nav-link" active-class="active" to="/">Home</router-link>
</li>
<li class="nav-item">
<router-link class="nav-link" active-class="active" to="/checkout">
Checkout
<span class="badge bg-light rounded-pill text-dark" v-text="cartSize"></span>
</router-link>
</li>
</ul>
<ul class="navbar-nav mb-2 mb-lg-0">
<li class="nav-item">
<router-link class="nav-link" active-class="active" to="/register">Register</router-link>
</li>
<li class="nav-item">
<router-link class="nav-link" active-class="active" to="/login">Login</router-link>
</li>
</ul>
</div>
</div>
</nav>
<div class="container">
<router-view/>
</div>
</template>
<script>
export default {
name: 'Checkout',
computed: {
cartSize() {
return this.$store.getters.getCartSize;
}
}
}
</script>
<style lang="scss"></style>
|