Skip to content

Instantly share code, notes, and snippets.

@uno-de-piera
Created September 10, 2019 15:07
Show Gist options
  • Save uno-de-piera/9fb3b2b246769c27e50ecdfc131ad269 to your computer and use it in GitHub Desktop.
Save uno-de-piera/9fb3b2b246769c27e50ecdfc131ad269 to your computer and use it in GitHub Desktop.
import { Auth } from "aws-amplify";
export async function getUser() {
try {
const user = await Auth.currentAuthenticatedUser();
return user;
} catch (e) {
console.log(e);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment