mirror of
https://github.com/teamhanko/hanko.git
synced 2025-10-29 15:49:41 +08:00
Add hanko profile to example apps (#618)
This commit is contained in:
15
examples/vue/src/components/HankoProfile.vue
Normal file
15
examples/vue/src/components/HankoProfile.vue
Normal file
@ -0,0 +1,15 @@
|
||||
<script setup lang="ts">
|
||||
import { register } from "@teamhanko/hanko-elements";
|
||||
import { onMounted } from "vue";
|
||||
|
||||
const api = import.meta.env.VITE_HANKO_API;
|
||||
const emit = defineEmits(["on-error"]);
|
||||
|
||||
onMounted(() => {
|
||||
register({ shadow: true }).catch((e) => emit("on-error", e));
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<hanko-profile :api="api" />
|
||||
</template>
|
||||
Reference in New Issue
Block a user