WordPress.org

Support

Support » Plugins and Hacks » [Plugin: Meteor Slides] use smaller javascript (cycle lite)

[Plugin: Meteor Slides] use smaller javascript (cycle lite)

  • Paul de Wouters

    @pauldewouters

    Human Made

    Hi,

    it would be great to add an option to select another jquery plugin, as for my use, the jquery cycle is too large.
    I’d like to use jquery cycle lite which has a smaller file size if I don’t need lots of settings, just a plain slideshow.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Josh Leuze

    @jleuze

    That’s a good idea Paul, I would like to do more to reduce the footprint of my plugin. Right now the uncompressed version of jQuery Cycle is included, I should switch to the minimized version. And I’m still working on getting the scripts to load only on pages with a slideshow.

    Paul de Wouters

    @pauldewouters

    Human Made

    this is what I did to replace the script in my theme functions.php:

    //replace meteor slides cycle plugin with more lightweight
    add_action( 'wp_print_scripts', 'my_deregister_javascript', 100 );
    
    function my_deregister_javascript() {
    	wp_deregister_script( 'jquery-cycle' );
    	wp_register_script('jquery-cycle', get_stylesheet_directory_uri() . '/js/jquery.cycle.lite.min.js', 'jquery');
    	wp_enqueue_script('jquery-cycle');
    }

    Plugin Author Josh Leuze

    @jleuze

    That’s a pretty slick way to do it Paul without hacking the plugin itself!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Plugin: Meteor Slides] use smaller javascript (cycle lite)’ is closed to new replies.