In that limited case, I supposed you don't 100% have to, but it's
still a **really** good idea.

First of all, you want your page to load before executing scripts.
There is nothing worse that JS failing half way through a page load,
it's faster to execute jQuery after the DOM has loaded, you can put
all your JS in one place and it's better coding style.

I guess the question is: what are you trying to gain by NOT wrapping
it in document.ready?

On Mar 4, 11:02 am, fetis <[EMAIL PROTECTED]> wrote:
> On Mar 3, 6:20 am, Hamish Campbell <[EMAIL PROTECTED]> wrote:
>
> >http://docs.jquery.com/How_jQuery_Works#Launching_Code_on_Document_Ready
>
> But I'm not needed in code that running after page loaded. I just want
> to add some class (for example) to already loaded element. Have I wrap
> it into ready() event?

Reply via email to