W3C home > Mailing lists > Public > whatwg@whatwg.org > September 2013

[whatwg] Proposal: q and qq for document.querySelector and document.querySelectorAll

From: Leon Gilyadov <leon.gilyadov@gmail.com>
Date: Wed, 18 Sep 2013 10:14:06 +0200
Message-ID: <CAAn7mYbM-f1cXJZEcDVRnxYppTDT+DJ78-cNdwVsA4qMpQ8=Vw@mail.gmail.com>
To: whatwg@lists.whatwg.org
*The problem:*
document.querySelector and document.querySelectorAll
are long and used a lot.

Lines in the code are long.

*Proposal:*
q('.my-div')
will be equal to:
document.querySelector('.my-div)

qq('.my-div')
will be equal to:
document.querySelectorAll('.my-div')


--Leon Gilyadov.
Received on Wednesday, 18 September 2013 08:14:30 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:09 UTC