We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
onMounted
onBeforeMount
1 parent 4fa7e8d commit 7f1fc3bCopy full SHA for 7f1fc3b
packages/coreui-vue/src/composables/useColorModes.ts
@@ -1,4 +1,4 @@
1
-import { onMounted, ref, watch } from 'vue'
+import { onBeforeMount, ref, watch } from 'vue'
2
3
const getStoredTheme = (localStorageItemName: string) => localStorage.getItem(localStorageItemName)
4
const setStoredTheme = (localStorageItemName: string, colorMode: string) =>
@@ -32,7 +32,7 @@ export const useColorModes = (localStorageItemName = 'coreui-vue-color-scheme')
32
setTheme(colorMode.value)
33
})
34
35
- onMounted(() => {
+ onBeforeMount(() => {
36
if (typeof getStoredTheme(localStorageItemName) === 'string') {
37
38
}
0 commit comments