File tree Expand file tree Collapse file tree 2 files changed +10
-16
lines changed Expand file tree Collapse file tree 2 files changed +10
-16
lines changed Original file line number Diff line number Diff line change @@ -24,13 +24,17 @@ const boards = ref<Partial<Board>[]>([
24
24
order: " []" ,
25
25
},
26
26
]);
27
+
28
+ function createBoard() {
29
+ console .log (" board created" );
30
+ }
27
31
</script >
28
32
29
33
<template >
30
34
<h1 class =" text-3xl mb-5" >Boards</h1 >
31
35
<div class =" flex" >
32
36
<BoardCard v-for =" board in boards" :key =" board.id" :board =" board" />
33
- <button class =" text-gray-500" @click =" createBoard(newBoardTemplate )" >
37
+ <button class =" text-gray-500" @click =" createBoard()" >
34
38
<span >New Board +</span >
35
39
</button >
36
40
</div >
Original file line number Diff line number Diff line change 1
- <script setup lang="ts"></script >
2
- <template >
3
- <div class =" flex justify-center items-center h-[80vh]" >
4
- <div class =" text-center" >
5
- <img
6
- class =" block"
7
- src =" https://vuejsforge.com/images/logo.svg"
8
- alt =" Vue.js Forge"
9
- />
10
- <AppButton class =" block" >
11
- <a href =" https://vi.to/hubs/vuejs-forge/" target =" _blank" >Get Started</a >
12
- </AppButton >
13
- </div >
14
- </div >
15
- </template >
1
+ <script lang="ts" setup>
2
+ import { useRouter } from " vue-router" ;
3
+ const router = useRouter ();
4
+ router .push (" /boards" );
5
+ </script >
You can’t perform that action at this time.
0 commit comments