Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
static checkBrowserFunctionalities(state, action) {
// Here we check for any missing browser functionalities that we
// want to alert the user about. Note, Modernizr checks are used elsewhere
// but those are not intended to inform the user that functionality is missing
let alerts = state.get("alerts");
if (!Modernizr.fullscreen) {
alerts = alerts.push(
alert.merge({
title: appStrings.ALERTS.BROWSER_FUNCTIONALITY_MISSING.title,
body: appStrings.ALERTS.BROWSER_FUNCTIONALITY_MISSING.formatString
.replace("{FUNCTIONALITY}", "Fullscreen")
.replace(
"{SYMPTOM}",
"This application will not be able to enter fullscreen mode"
),
severity: 2,
time: new Date()
})
);
}
if (!Modernizr.webgl) {
alerts = alerts.push(