feat: PWA using @vite-pwa/nuxt module with auto update strategy (#75)
Co-authored-by: Anthony Fu <anthonyfu117@hotmail.com>
This commit is contained in:
1 parent
575149c356
commit
ac3bac5513
20 files changed
+2558
-705
No files matched your search
@@ -1,6 +1,14 @@
|
||||
<script setup lang="ts">
|
||||
const color = useColorMode()
|
||||
|
||||
useHead({
|
||||
meta: [{
|
||||
id: 'theme-color',
|
||||
name: 'theme-color',
|
||||
content: () => color.value === 'dark' ? '#222222' : '#ffffff',
|
||||
}],
|
||||
})
|
||||
|
||||
function toggleDark() {
|
||||
color.preference = color.value === 'dark' ? 'light' : 'dark'
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user