Created
December 18, 2019 04:01
-
-
Save bishawjit-das/b41f85c03105879febc72d4eb9995d73 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| <script> | |
| async function start() { | |
| if ('storage' in navigator && 'estimate' in navigator.storage) { | |
| const {usage, quota} = await navigator.storage.estimate(); | |
| console.log(`Using ${usage} out of ${quota} bytes.`); | |
| if(quota < 120000000){ | |
| alert('We see you! You are incognito!') | |
| console.log('Incognito') | |
| } else { | |
| alert('Not incognito!') | |
| console.log('Not Incognito') | |
| } | |
| } else { | |
| console.log('Can not detect') | |
| } | |
| } | |
| start(); | |
| </script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment