📌  相关文章
📜  jquery 检查一个类是否存在 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:04:15.993000             🧑  作者: Mango

代码示例2
/* Answer to: "jquery check if element has class starting with" */

if(!$(this).is('[class*="answerbox"]')) {
    //Finds element with no answerbox class
} else {
    //The element has already an answerbox class
}