收录日期:2019/12/07 12:22:21 时间:2010-10-30 22:49:26 标签:javascript,jquery,jquery-plugins,qtip

I'm passing options to the qTip plugin like so:

hide: { 
        when: { 
            event: 'unfocus',
            event: 'inactive',
            event: 'click' 
        },
}, 

It appears to be working but should I bundle those 'events' somehow?

In the qTip case specifically, it the inactve event is special and binds all of the others, it's best to just use it that way, like this:

hide: { 
    when: { 
        event: 'inactive'
    }
}, 

Or just:

hide: { when: 'inactive' },