What is the Dojo equivalent of jQuery's scope attribute?

Posted by joolss on Stack Overflow See other posts from Stack Overflow or by joolss
Published on 2010-03-25T15:06:50Z Indexed on 2010/03/25 15:33 UTC
Read the original article Hit count: 298

Filed under:
|
|
|

Hi. I'm a Dojo n00b.

In jQuery, a DOM node or jQuery object can be passed as an attribute in a query, which sets the scope:

var myScope = $('#someDiv');
$('a',myScope).addClass('red');
$('li',myScope).css('display','inline');

Now, in Dojo I can chain several .query()s after each other, but what should I do if I have a certain DOM node - not a nodeList - that I want to use as a scope?

KTHNX

© Stack Overflow or respective owner

Related posts about dojo

Related posts about jQuery