Does Dojo have an equivalent to jQuery.trigger()?

后端 未结 7 1084
情书的邮戳
情书的邮戳 2020-12-11 02:11

In jQuery, you can do this:

$(\'#myElement\').trigger(\'change\');

How do I do that in Dojo?

7条回答
  •  旧巷少年郎
    2020-12-11 03:04

    I recently stumbled upon Dojo's publish/subscribe mechanism, and I think this is the counterpart to jQuery's bind/trigger.

    Links:

    • Events with Dojo (v1.6)
    • dojo.publish reference guide

提交回复
热议问题