Developing Secure Code
Testing Components
addClass()
getBooleanValue()
hasClass()
isArray()
isEmpty()
isObject()
isUndefined()
isUndefinedOrNull()
removeClass()
toggleClass()
Previous PDF Versions
Util contains utility methods.
Adds a CSS class to a component.
Coerces truthy and falsy values into a native boolean.
Checks whether the component has the specified CSS class.
Checks whether the specified object is an array.
Checks if the object is empty. An empty object’s value is undefined, null, an empty array, or an empty string. An object with no native properties is not considered empty.
Checks whether the specified object is a valid object. A valid object is not a DOM element, is not a native browser class (XMLHttpRequest) is not falsey, and is not an array, error, function string or a number.
Checks if the object is undefined.
Checks if the object is undefined or null.
Removes a CSS class from a component.
Toggles (adds or removes) a CSS class from a component.