What does the @ sign in jQuery selector mean?

What does the sign mean @in the following code?

$("input[@type=checkbox][@checked]").each(
    function() {
        ...
    }
);
+5
source share
1 answer

This is the xpath convention for selecting an attribute that was discontinued two versions ago.
You must remove the character @if you want the selectors to work on the current version.

Alternatively, the selector $("input:checkbox:checked")should work in exactly the same way.

+15
source

All Articles