Files
timmal/app/components/ui/logout.vue
Lucien Cartier-Tilet ea28a87860
All checks were successful
ci / ci (push) Successful in 19m53s
feat: authentication with OAuth
2025-12-10 21:21:38 +01:00

19 lines
493 B
Vue
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<template>
<UButton color="neutral" variant="ghost" icon="i-lucide-log-out" size="xl" @click="onLogout"> Log Out </UButton>
</template>
<script setup lang="ts">
const { logout } = useAuth();
const toast = useToast();
const onLogout = () => {
logout();
navigateTo('/');
toast.add({
title: 'Successfully logged out!',
description: 'You successfully logged out of your account and have been taken back to the websites welcome page.',
color: 'success',
});
};
</script>