Skip to content
On this page

hasClassName

判断dom元素中是否存在指定的class名称

使用

js
import { hasClassName } from '@pinos-ui/utils'

代码示例

参数说明

参数名说明类型必传默认值
el目标元素HTMLElement-
clsclass样式类名string-

类型声明

js
export declare const hasClassName: (el: HTMLElement, cls: string) => boolean