addClass()
function, you can remove them with jQuery's removeClass()
function.
Here's how you would do this for a specific button:
$("#target2").removeClass("btn-default");
Let's remove the btn-default
class from all of our button
elements.
btn-default
class from all of your button
elements.
testString: 'assert($(".btn-default").length === 0, "Remove the btn-default
class from all of your button
elements.");'
- text: Only use jQuery to remove this class from the element.
testString: 'assert(code.match(/btn btn-default/g), "Only use jQuery to remove this class from the element.");'
- text: Only remove the btn-default
class.
testString: 'assert(code.match(/\.[\v\s]*removeClass[\s\v]*\([\s\v]*("|")\s*btn-default\s*("|")[\s\v]*\)/gm), "Only remove the btn-default
class.");'
```