-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
15 changed files
with
163 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,23 @@ | ||
<script setup> | ||
import { RouterView } from 'vue-router' | ||
import HeaderNav from './components/HeaderNav.vue'; | ||
import HeaderNav from './components/HeaderNav.vue' | ||
import { computed } from 'vue' | ||
import { useRouter } from 'vue-router' | ||
// 路由缓存 | ||
const keepAliveRoutes = computed(() => { | ||
const routes = useRouter().options.routes | ||
// 存在meta.keepAlive的路由,会根据name进行缓存 | ||
return routes.filter((item) => item.meta?.keepAlive).map((item) => item.name) | ||
}) | ||
</script> | ||
<template> | ||
<HeaderNav /> | ||
<RouterView /> | ||
<HeaderNav /> | ||
<router-view v-slot="{ Component }"> | ||
<keep-alive :include="keepAliveRoutes"> | ||
<component :is="Component" /> | ||
</keep-alive> | ||
</router-view> | ||
</template> | ||
<style lang="scss" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<template> | ||
<svg class="icon" width="20" height="20" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3 22h18a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-4V3a1 1 0 0 0-2 0v2H9V3a1 1 0 0 0-2 0v2H3a1 1 0 0 0-1 1v15a1 1 0 0 0 1 1ZM4 7h16v3H4Zm0 5h16v8H4Z"/></svg> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<template> | ||
<svg class="icon" width="800" height="800" viewBox="0 0 36 36" xmlns="http://www.w3.org/2000/svg"><path class="clr-i-outline clr-i-outline-path-1" d="M32 6H4a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h28a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2Zm-1.54 22H5.66l7-7.24-1.44-1.39L4 26.84V9.52l12.43 12.37a2 2 0 0 0 2.82 0L32 9.21v17.5l-7.36-7.36-1.41 1.41ZM5.31 8h25.07L17.84 20.47Z"/><path fill="none" d="M0 0h36v36H0z"/></svg> | ||
</template> |
File renamed without changes.
1 change: 1 addition & 0 deletions
1
src/components/icons/IconImage.vue → src/components/icons/image.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
<template> | ||
<svg | ||
class="icon" | ||
width="25px" | ||
height="25px" | ||
viewBox="0 0 17 17" | ||
|
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
export default { | ||
userName:'sunwenxu', | ||
email:'[email protected]', | ||
github:'https://github.com/sunwenxu1997', | ||
juejin:'https://juejin.cn/user/1291397693', | ||
githubLink: 'https://github.com/sunwenxu1997/sunwenxu1997.github.io', | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,67 @@ | ||
<script setup> | ||
import { ref, reactive, onMounted } from 'vue' | ||
onMounted(() => { }) | ||
import IconGithub from '@/components/icons/github.vue' | ||
import IconEmail from '@/components/icons/email.vue' | ||
import defaultSet from '../settings' | ||
onMounted(() => {}) | ||
</script> | ||
<template> | ||
<div | ||
class="pt-28 px-12 sm:px-60 text-xs tracking-widest sm:max-w-screen-sm sm:m-auto selection:bg-stone-700 selection:text-white"> | ||
<p>关于作者是个菜鸡🐔。</p> | ||
<br><br><br> | ||
<p> | ||
日常划水积累的小项目,包含 | ||
<span class="font-bold underline text-sm">css</span>、 | ||
<span class="font-bold underline text-sm">html</span>、 | ||
<span class="font-bold underline text-sm">js</span>、 | ||
<span class="font-bold underline text-sm">vue</span>、 | ||
<span class="font-bold underline text-sm">gsap</span>、 | ||
<span class="font-bold underline text-sm">threejs</span>、 | ||
<span class="font-bold underline text-sm">tailwindcss</span>等。 | ||
</p> | ||
<p>大多是以动画效果形式展示,方便有效理解和提起我的兴趣。偶尔我自己也会翻着看🤣</p> | ||
<p> | ||
自己也有写相关的文章,主要在平台 | ||
<a class="text-sm text-stone-800 font-bold" href="https://juejin.cn/user/1011206430666551/posts?sort=popular" | ||
target="_blank">掘金</a>、 | ||
<a class="text-sm text-stone-800 font-bold" href="https://www.jianshu.com/u/5294c349f0f1" | ||
target="_blank">简书(弃用)</a>都有记录,你也可以通过 | ||
<a class="text-sm text-stone-800 font-bold" href="https://github.com/sunwenxu1997" | ||
target="_blank">Github</a>找到我, 欢迎交流👾。 | ||
</p> | ||
</div> | ||
<div | ||
class="pt-28 px-12 sm:px-60 text-xs tracking-widest sm:max-w-screen-sm sm:m-auto selection:bg-stone-700 selection:text-white" | ||
> | ||
<p>关于作者是个菜鸡🐔。</p> | ||
<br /> | ||
<p> | ||
日常划水积累的小项目,包含 | ||
<span class="font-bold underline text-sm">css</span>、 | ||
<span class="font-bold underline text-sm">html</span>、 | ||
<span class="font-bold underline text-sm">js</span>、 | ||
<span class="font-bold underline text-sm">vue</span>、 | ||
<span class="font-bold underline text-sm">gsap</span>、 | ||
<span class="font-bold underline text-sm">threejs</span>、 | ||
<span class="font-bold underline text-sm">tailwindcss</span>等。 | ||
</p> | ||
<p>大多是以动画效果形式展示,方便有效理解和提起我的兴趣。偶尔我自己也会翻着看🤣</p> | ||
<p> | ||
自己也有写相关的文章,主要在平台 | ||
<a | ||
class="text-sm text-stone-800 font-bold" | ||
href="https://juejin.cn/user/1011206430666551/posts?sort=popular" | ||
target="_blank" | ||
>掘金</a | ||
>、 | ||
<a | ||
class="text-sm text-stone-800 font-bold" | ||
href="https://www.jianshu.com/u/5294c349f0f1" | ||
target="_blank" | ||
>简书(弃用)</a | ||
>都有记录,你也可以通过 | ||
<a | ||
class="text-sm text-stone-800 font-bold" | ||
href="https://github.com/sunwenxu1997" | ||
target="_blank" | ||
>Github</a | ||
>找到我, 欢迎交流👾。 | ||
</p> | ||
<br /><br /><br /> | ||
<p class="mb-2 flex items-center select-none"> | ||
<IconEmail class="mr-2" /> | ||
<a | ||
:href="'mailto:' + defaultSet.email" | ||
class="text-stone-800 text-sm font-bold hover:opacity-50 hover:no-underline" | ||
rel="email" | ||
>{{ defaultSet.email }}</a | ||
> | ||
</p> | ||
<p class="mb-2 flex items-center select-none"> | ||
<IconGithub class="mr-2" /> | ||
<a | ||
:href="defaultSet.github" | ||
class="text-stone-800 text-sm font-bold hover:opacity-50 hover:no-underline" | ||
target="_blank" | ||
>Github.com</a | ||
> | ||
</p> | ||
</div> | ||
</template> | ||
<style lang="scss" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters