Posts

Showing posts from 2020

Validate Google access token?

  For user check, just post get the access token as accessToken and post it and get the response https://www.googleapis.com/oauth2/v1/tokeninfo?access_token=accessToken you can try in address bar in browsers too, use httppost and response in java also response will be like { "issued_to": "xxxxxxxxxxxxx-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com", "audience": "xxxxxxxxxxxxxxx-xxxxxxxxxxxxxxxxxxxxxxxxxx.apps.googleusercontent.com", "user_id": "xxxxxxxxxxxxxxxxxxxxxxx", "scope": "https://www.googleapis.com/auth/userinfo.profile https://gdata.youtube.com", "expires_in": 3340, "access_type": "offline" } The scope is the given permission of the accessToken. you can check the scope ids in  this link Update:  New API post as below https://oauth2.googleapis.com/tokeninfo?id_token=XYZ123 Response will be as { // These six fields are

Javascript key codes

Key Code Key 0 That key has no keycode 3 break 8 backspace / delete 9 tab 12 clear 13 enter 16 shift 17 ctrl 18 alt 19 pause/break 20 caps lock 21 hangul 25 hanja 27 escape 28 conversion 29 non-conversion 32 spacebar 33 page up 34 page down 35 end 36 home 37 left arrow 38 up arrow 39 right arrow 40 down arrow 41 select 42 print 43 execute 44 Print Screen 45 insert 46 delete 47 help 48 0 49 1 50 2 51 3 52 4 53 5 54 6 55 7 56 8 57 9 58 : 59 semicolon (firefox), equals 60 < 61 equals (firefox) 63 ß 64 @ (firefox) 65 a 66 b 67 c 68 d 69 e 70 f 71 g 72 h 73 i 74 j 75 k 76 l 77 m 78 n 79 o 80 p 81 q 82 r 83 s 84 t 85 u 86 v 87 w 88 x 89 y 90 z 91 Windows Key / Left ⌘ / Chromebook Search key 92 right window key 93 Windows Menu / Right ⌘ 95 sleep 96 numpad 0 97 numpad 1 98 numpad 2 99 numpad 3 100 numpad 4 101 numpad 5 102 numpad 6 103 numpad 7 104 numpad 8

Run react-native with emulator

List Emulator Devices:   emulator -list-avds Example:  Pixel_2_API_28 Run app with emulator: emulator @{device_name} & react-native run-android Example:  emulator @{Pixel_2_API_28} & react-native run-android