UNPKG

@reown/appkit-siwx

Version:

The chain agnostic tool to enable authentication for AppKit applications.

16 lines 496 B
import { onMounted, onUnmounted, ref } from 'vue'; import { OptionsController } from '@reown/appkit-controllers'; export function useAppKitSIWX() { const state = ref(OptionsController.state.siwx); const unsubscribe = OptionsController.subscribeKey('siwx', val => { state.value = val; }); onMounted(() => { state.value = OptionsController.state.siwx; }); onUnmounted(() => { unsubscribe(); }); return state; } //# sourceMappingURL=vue.js.map