2022-02-04 16:28:24 +00:00

34 lines
570 B
Plaintext

Using element type in class selectors is slower than using only the class selector.
== Noncompliant Code Example
[source,javascript]
----
var $products = $("div.products"); // Noncompliant - slow
----
== Compliant Solution
[source,javascript]
----
var $products = $(".products"); // Compliant - fast
----
ifdef::env-github,rspecator-view[]
'''
== Implementation Specification
(visible only on this page)
include::message.adoc[]
'''
== Comments And Links
(visible only on this page)
include::comments-and-links.adoc[]
endif::env-github,rspecator-view[]