From 90c5336cd15038067d90d72694eb7a3cb3813f62 Mon Sep 17 00:00:00 2001 From: Chiebidolu Chinaemerem Date: Thu, 22 Feb 2024 01:03:01 +0100 Subject: [PATCH 01/15] Fix: @vueuse/head doesn't function properly with ionic I figured out that the author of @vueuse/head, @egoist, suggested that developers should go for the unhead package, and so I decided to create an utility function with unhead, to handle tags management accurately, irrespective of the Ionic hooks randomness. Note: There is also support for nested head calls within components --- package.json | 1 + playground/app.vue | 10 +++ playground/components/ExploreContainer.vue | 7 +- playground/composables/usePhotoGallery.ts | 2 +- playground/nuxt.config.ts | 1 + playground/package.json | 6 +- playground/pages/overlap.vue | 6 ++ playground/pages/tabs.vue | 7 +- playground/pages/tabs/tab1/index.vue | 14 +++- playground/pages/tabs/tab2/index.vue | 8 +- playground/pages/tabs/tab3/index.vue | 6 ++ playground/pages/tabs/tab3/page-two.vue | 6 ++ playground/pages/tabs/tab4/index.vue | 42 +++++----- src/module.ts | 24 +++--- src/parts/components.ts | 9 +-- src/parts/css.ts | 4 +- src/parts/router.ts | 11 ++- src/utils.ts | 92 +++++++++++++++++++++- 18 files changed, 203 insertions(+), 53 deletions(-) create mode 100644 playground/app.vue diff --git a/package.json b/package.json index e84f2509..b4954e13 100644 --- a/package.json +++ b/package.json @@ -61,6 +61,7 @@ "@ionic/vue-router": "^7.6.3", "@kevinmarrec/nuxt-pwa": "^0.17.0", "@nuxt/kit": "^3.9.1", + "@unhead/vue": "^1.8.10", "ionicons": "^7.2.2", "pathe": "^1.1.1", "pkg-types": "^1.0.3", diff --git a/playground/app.vue b/playground/app.vue new file mode 100644 index 00000000..888aeb0b --- /dev/null +++ b/playground/app.vue @@ -0,0 +1,10 @@ + + + + \ No newline at end of file diff --git a/playground/components/ExploreContainer.vue b/playground/components/ExploreContainer.vue index 2bac2ed0..8a08ee06 100644 --- a/playground/components/ExploreContainer.vue +++ b/playground/components/ExploreContainer.vue @@ -1,5 +1,10 @@