import React, { useContext, useState } from 'react'; import { View, Text, StyleSheet, TouchableOpacity, Linking, Button } from 'react-native'; import { QRCodeContext } from '../types'; import { useAuthenticator } from '@aws-amplify/ui-react-native'; import { fetchUserAttributes } from 'aws-amplify/auth'; import useFetchUserAttributes from '../hooks/useFetchUserAttributes'; async function handleFetchUserAttributes() { try { const userAttributes = await fetchUserAttributes(); console.log(userAttributes); } catch (error) { console.log(error); } } function SignOutButton() { const { signOut } = useAuthenticator(); return