Created
February 13, 2019 04:36
-
-
Save rustemkk/fec0a25eb6156b5b0358ed7045745a5a to your computer and use it in GitHub Desktop.
simple google sign in button
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta name="google-signin-scope" content="profile email"> | |
<meta name="google-signin-client_id" | |
content="242027652015-1jjfj1vtp3ftff6o39r3k904ug77ucki.apps.googleusercontent.com"> | |
<script src="https://apis.google.com/js/platform.js" async defer></script> | |
</head> | |
<body> | |
<div class="g-signin2" data-onsuccess="onSignIn" data-onfailure="onFailure" data-theme="dark"></div> | |
<script> | |
function onSignIn(googleUser) { | |
console.log('onSignIn', googleUser); | |
} | |
function onFailure(res) { | |
console.log('onFail', res); | |
} | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment