Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #26315

Re: jquery and hoi polloi

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!feeder1.news.weretis.net!news.solani.org!.POSTED!not-for-mail
From "Christoph M. Becker" <cmbecker69@arcor.de>
Newsgroups comp.lang.javascript
Subject Re: jquery and hoi polloi
Date Thu, 11 Dec 2014 22:52:02 +0100
Organization solani.org
Lines 24
Message-ID <m6d3lr$d2c$1@solani.org> (permalink)
References <svOdnVxF-e8OrePJnZ2dnUVZ8q2dnZ2d@westnet.com.au> <3e25f0fa-4c3f-4d51-a6a0-da69bd8b3677@googlegroups.com> <27938323-9eca-480c-8ead-2000865bcecc@googlegroups.com> <82684c28-b567-4b2c-8d2b-eb0c41376cd2@googlegroups.com> <m6aupe$esl$1@solani.org> <43afda5d-d558-475d-bf46-4a9e69d99b8e@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 7bit
X-Trace solani.org 1418334715 13388 eJwFwYcBwDAIA7CXyrAh5ySM/0+oBKOwwgk6Fjs5iugBKJf4XlehI+vY6N5qnwVe0fRIJ38sFBGi (11 Dec 2014 21:51:55 GMT)
X-Complaints-To abuse@news.solani.org
NNTP-Posting-Date Thu, 11 Dec 2014 21:51:55 +0000 (UTC)
User-Agent Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.3.0
X-User-ID eJwFwQkBwDAIA0BLUEhY5ZTPv4TdwaiscIKOxc5AQxffkcrajuCkW1HgkCfF5E1/bOOw+wcg7BFf
In-Reply-To <43afda5d-d558-475d-bf46-4a9e69d99b8e@googlegroups.com>
Cancel-Lock sha1:pWLMsfIRmOc2sl80V03gFmqBGuw=
X-NNTP-Posting-Host eJwNycERwDAIA7CVcAI2HYfCsf8Irb6KS7DlDHpsbOGMGyvi0dZRltf4pukqE3o56L962wDwAxEuEKQ=
Xref csiph.com comp.lang.javascript:26315

Show key headers only | View raw


Cezary Tomczyk wrote:

> There is nothing wrong with document.getElementById. However, if the
> whole application is already using jQuery and then you'll start
> "mixing" it with native JavaScript (in some places $(...) and in some
> places getElementById) then you might get feedback from others that
> you are breaking consistency of code.

Good point.  However, sometimes you have to use native APIs, because
jQuery doesn't offer wrappers for all of them, anyway.

And, for instance, the official "How to Create a Basic Plugin"
tutorial[1] says:

| Notice also that we're not using the .attr() method to retrieve the
| href attribute, because the native DOM API gives us easy access with
| the aptly named href property.

... and it saves you a dollar. ;)

[1] <http://learn.jquery.com/plugins/basic-plugin-creation>

-- 
Christoph M. Becker

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

jquery and hoi polloi Andrew Poulos <ap_prog@hotmail.com> - 2014-12-03 08:30 +1100
  Re: jquery and hoi polloi "Christoph M. Becker" <cmbecker69@arcor.de> - 2014-12-02 23:33 +0100
    Re: jquery and hoi polloi "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2014-12-04 21:46 -0800
      Re: jquery and hoi polloi "Christoph M. Becker" <cmbecker69@arcor.de> - 2014-12-10 00:47 +0100
  Re: jquery and hoi polloi danca <cyberdanny@tiscalinet.it> - 2014-12-03 00:14 +0100
  Re: jquery and hoi polloi Erwin Moller <erwinmollerusenet@xs4all.nl> - 2014-12-03 14:47 +0100
  Re: jquery and hoi polloi Gregor Kofler <usenet@gregorkofler.com> - 2014-12-03 16:44 +0100
    Re: jquery and hoi polloi Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2014-12-04 22:06 +0100
  Re: jquery and hoi polloi RobG <rgqld@iinet.net.au> - 2014-12-08 18:39 -0800
    Re: jquery and hoi polloi Cezary Tomczyk <cezary.tomczyk@gmail.com> - 2014-12-09 13:23 -0800
      Re: jquery and hoi polloi RobG <rgqld@iinet.net.au> - 2014-12-10 17:00 -0800
        Re: jquery and hoi polloi "Christoph M. Becker" <cmbecker69@arcor.de> - 2014-12-11 03:16 +0100
          Re: jquery and hoi polloi RobG <rgqld@iinet.net.au> - 2014-12-10 18:37 -0800
          Re: jquery and hoi polloi Cezary Tomczyk <cezary.tomczyk@gmail.com> - 2014-12-11 11:08 -0800
            Re: jquery and hoi polloi "Christoph M. Becker" <cmbecker69@arcor.de> - 2014-12-11 22:52 +0100
  Re: jquery and hoi polloi Scott Sauyet <scott.sauyet@gmail.com> - 2014-12-16 12:56 -0800

csiph-web