UADetect cookieStatus
Componet
Description
Tell's whether the client has cookies enabled or disabled.
Possible Returns
cookiesEnables
cookiesNotEnabled
ERROR
Usage Example
#1
import { cookieStatus } from 'uadetect';if (cookieStatus === 'COOKIES_enabled') { document.cookie = 'test=test';}
#2
import { cookieStatus } from 'uadetect';if (cookieStatus === 'COOKIES_notEnabled') { element.innerHTML = 'You should enable cookies to use this website';}
Table of Contents