Skip to content

Commit

Permalink
inject global var for no app version to show
Browse files Browse the repository at this point in the history
  • Loading branch information
amiraabouhadid committed Oct 15, 2024
1 parent bb7fe3f commit 05603b9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/playground/src/components/main_footer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
</template>

<script lang="ts" setup>
import { ref } from "vue";
import { inject } from "vue";
import { useRouter } from "vue-router";
import { useTheme } from "vuetify";
Expand All @@ -111,7 +111,7 @@ const theme = useTheme();
const version = process.env.VERSION as any;
const baseUrl = import.meta.env.BASE_URL;
const $router = useRouter();
const message = ref("No version to show");
const message = inject("noAppVersion");
function navigateToHome() {
return $router.push(DashboardRoutes.Other.HomePage);
}
Expand Down
2 changes: 1 addition & 1 deletion packages/playground/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import { defineGlobals } from "./config";
import Monitor from "./Monitor.vue";
import router from "./router";
import { normalizeError } from "./utils/helpers";

const app = createApp(Monitor);

app.config.errorHandler = error => {
Expand Down Expand Up @@ -43,5 +42,6 @@ app.use(createPinia());
app.use(router);
app.use(vuetify);
defineGlobals(app);
app.provide("noAppVersion", "No version to show");

app.mount("#app");

0 comments on commit 05603b9

Please sign in to comment.