参考 hasClass()

hasClass()

Checks if a class is already applied to element.

示例

语法

hasClass(c)

参数

c
{String} name of class to check.

返回值

boolean: a boolean value if element has specified class.

相关参考