|
1 | 1 | <template>
|
2 |
| - <div class="container"> |
3 |
| - <nav class="navbar navbar-default"> |
4 |
| - <div class="container-fluid"> |
5 |
| - <div class="navbar-header"> |
6 |
| - <router-link to="/" exact class="navbar-brand"><strong>E-commerce Inc.</strong></router-link> |
7 |
| - </div> |
| 2 | + <div> |
| 3 | + <router-view name="discount"></router-view> |
| 4 | + |
| 5 | + <div class="container"> |
| 6 | + <nav class="navbar navbar-default"> |
| 7 | + <div class="container-fluid"> |
| 8 | + <div class="navbar-header"> |
| 9 | + <router-link to="/" exact class="navbar-brand"><strong>E-commerce Inc.</strong></router-link> |
| 10 | + </div> |
8 | 11 |
|
9 |
| - <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1"> |
10 |
| - <ul class="nav navbar-nav"> |
11 |
| - <router-link to="/" tag="li" exact active-class="active"> |
12 |
| - <a>Products</a> |
13 |
| - </router-link> |
| 12 | + <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1"> |
| 13 | + <ul class="nav navbar-nav"> |
| 14 | + <router-link to="/" tag="li" exact active-class="active"> |
| 15 | + <a>Products</a> |
| 16 | + </router-link> |
14 | 17 |
|
15 |
| - <router-link to="/cart" tag="li" active-class="active"> |
16 |
| - <a>Cart</a> |
17 |
| - </router-link> |
18 |
| - </ul> |
| 18 | + <router-link to="/cart" tag="li" active-class="active"> |
| 19 | + <a>Cart</a> |
| 20 | + </router-link> |
| 21 | + </ul> |
19 | 22 |
|
20 |
| - <div class="nav navbar-nav navbar-right"> |
21 |
| - <div class="stats">{{ cart.items.length }} <template v-if="cart.items.length == 1">item</template><template v-else>items</template> in cart, totalling {{ cartTotal | currency }}</div> |
| 23 | + <div class="nav navbar-nav navbar-right"> |
| 24 | + <div class="stats">{{ cart.items.length }} <template v-if="cart.items.length == 1">item</template><template v-else>items</template> in cart, totalling {{ cartTotal | currency }}</div> |
| 25 | + </div> |
22 | 26 | </div>
|
23 | 27 | </div>
|
24 |
| - </div> |
25 |
| - </nav> |
| 28 | + </nav> |
26 | 29 |
|
27 |
| - <router-view :cart="cart"></router-view> |
| 30 | + <router-view :cart="cart"></router-view> |
| 31 | + </div> |
28 | 32 | </div>
|
29 | 33 | </template>
|
30 | 34 |
|
|
0 commit comments