Title: Performance issues
Last modified: November 21, 2017

---

# Performance issues

 *  [Etienne](https://wordpress.org/support/users/epipo/)
 * (@epipo)
 * [8 years, 6 months ago](https://wordpress.org/support/topic/performance-issues-25/)
 * Hello,
 * This plugin is awesome, thanks a lot for your work. To make it even better you
   might consider increasing performance by:
 * – Loading photoswipe js only on pages where a gallery is used.
    – Loading scripts
   in footer instead of header (or at least trying to reduce the number of scripts
   in header). – I don’t think you need to enqueue jQuery again, as it is included
   in wordpress just loading it as a dependency of your other scripts should prevent
   any extra loading.
 * Thanks a lot!
    -  This topic was modified 8 years, 6 months ago by [Etienne](https://wordpress.org/support/users/epipo/).
    -  This topic was modified 8 years, 6 months ago by [Etienne](https://wordpress.org/support/users/epipo/).
    -  This topic was modified 8 years, 6 months ago by [Etienne](https://wordpress.org/support/users/epipo/).
    -  This topic was modified 8 years, 6 months ago by [Etienne](https://wordpress.org/support/users/epipo/).

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Plugin Author [THRIVE – Web Design Gold Coast](https://wordpress.org/support/users/deanoakley/)
 * (@deanoakley)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9751031)
 * Hi,
 * Thanks for the feedback. You might want to check out the new version
 * [https://github.com/thriveweb/photoswipe-masonry-v2](https://github.com/thriveweb/photoswipe-masonry-v2)–
   We would love some dev help!
 * I’ll publish this soon as a separate plugin.
 *  [Happy Coder](https://wordpress.org/support/users/lovemesomecode/)
 * (@lovemesomecode)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9774820)
 * Checked the repo and could not find jQuery except in these two files
 * [https://github.com/thriveweb/photoswipe-masonry-v2/blob/master/frontend/js/photoswipe-masonry.js](https://github.com/thriveweb/photoswipe-masonry-v2/blob/master/frontend/js/photoswipe-masonry.js)
 * [https://github.com/thriveweb/photoswipe-masonry-v2/blob/master/frontend/js/photoswipe-lazyload.js](https://github.com/thriveweb/photoswipe-masonry-v2/blob/master/frontend/js/photoswipe-lazyload.js)
 * Proposal, what would it cost to have your guys write that in vanilla JS?
 * Happy to pay for a vanilla JS version of this plugin. Photoswipe itself is vanilla
   JS, that being one of the reasons what makes it so fast.
 * Would get cracking at it myself however still learning. Seeing that the old version
   uses jQuery in \wp-content\plugins\photoswipe-masonry\photoswipe-masonry.js made
   me sad as this is a HUGE payload for the site. Generally I am trying to keep 
   away from an plugins that use jQuery. Writing it all in vanilla JS could speed
   this thing up plenty fold.
 * Managed to get 100% on the GPSI (Google PageSpeed Insights) score though by inlining
   the jQuery load and moving registered and enqueued stylesheets and script to 
   footer and partly loading them async. However all this can be avoided with some
   vanilla JS.
 * What do you think?
    Also is the repo you linked under active development? There
   are lots of issues/improvements happening, be sure I am watching this very closely.
   Thank you heaps for your effort. Let me know if I can be of any help, thank you.
   Perhaps you could get donations going to support your dev time? I am sure if 
   a couple of people support your work hours this could be done in no time.
    -  This reply was modified 8 years, 5 months ago by [Happy Coder](https://wordpress.org/support/users/lovemesomecode/).
      Reason: added more text
 *  Plugin Author [THRIVE – Web Design Gold Coast](https://wordpress.org/support/users/deanoakley/)
 * (@deanoakley)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9794915)
 * Hi,
 * I think it is a good idea to get rid of jQuery.
 * If you want to discuss costs please email me [dean@thriveweb.com.au](https://wordpress.org/support/topic/performance-issues-25/dean@thriveweb.com.au?output_format=md)
   🙂
 * V2 I will release soon as a separate plugin.
 * We fix major bugs quickly but don’t have a lot of time for improvements at the
   moment sorry.
 *  [Happy Coder](https://wordpress.org/support/users/lovemesomecode/)
 * (@lovemesomecode)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9801557)
 * Thank you.
 * Will V2 still use jQuery?
 * As it stands V1 is quite solid except using jQuery, whereas the issues for V2
   are quite numerous looking at the repo.
 * Do you think or are of the impression that V2 is so much better than V1?
 * Thank you.
 *  Plugin Author [THRIVE – Web Design Gold Coast](https://wordpress.org/support/users/deanoakley/)
 * (@deanoakley)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9802137)
 * I’ll have to check how much jQuery there is.
 * v2 was completely re-written and should be easier to build on.
 *  [tobiasmalikowski](https://wordpress.org/support/users/tobiasmalikowski/)
 * (@tobiasmalikowski)
 * [8 years, 4 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9896914)
 * Hi there,
 * when will v2 be released? The performance issues with v1 are crucial and I need
   to fix this as asap, otherwise i have to switch to another gallery plugin.
 * Is v2 already ready to use? I’ve installed it (WordPress 4.9.2), but instantly
   run into errors like “Undefined index: item_count in frontend/class-psm-frontend.
   php on line 94”. Even activating the plugin gave me an error “the plugin created
   243 characters unexpected output while activating.”
 * Cheers,
 * Tobias
    -  This reply was modified 8 years, 4 months ago by [tobiasmalikowski](https://wordpress.org/support/users/tobiasmalikowski/).

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Performance issues’ is closed to new replies.

 * ![](https://ps.w.org/photoswipe-masonry/assets/icon-128x128.png?rev=3464802)
 * [Photoswipe Masonry Gallery](https://wordpress.org/plugins/photoswipe-masonry/)
 * [Support Threads](https://wordpress.org/support/plugin/photoswipe-masonry/)
 * [Active Topics](https://wordpress.org/support/plugin/photoswipe-masonry/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/photoswipe-masonry/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/photoswipe-masonry/reviews/)

 * 6 replies
 * 4 participants
 * Last reply from: [tobiasmalikowski](https://wordpress.org/support/users/tobiasmalikowski/)
 * Last activity: [8 years, 4 months ago](https://wordpress.org/support/topic/performance-issues-25/#post-9896914)
 * Status: not a support question