How can I check to see that a specific easing method is defined? For example, jQuery includes two methods ("linear" and "swing"), jQuery UI has a bunch more and there are also third-party plugins that have even more methods. In my plugin, I let developers specify an easing method but it is up to them to include the proper files which define those methods, so I want to check and display an error if they have specified 开发者_如何转开发an easing method which does not exist.
I believe it should be as easy as:
jQuery.easing['swing'] != undefined    // -> true
jQuery.easing['foobar'] != undefined   // -> false
 
         
                                         
                                         
                                         
                                        ![Interactive visualization of a graph in python [closed]](https://www.devze.com/res/2023/04-10/09/92d32fe8c0d22fb96bd6f6e8b7d1f457.gif) 
                                         
                                         
                                         
                                         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论