Support » Plugin: PDF Flipbook, 3D Flipbook WordPress - DearFlip » Aloads unused js 35kb impacting site speed

  • Reduce unused JavaScript 1.37s

    s/dflip.min.js?ver=1.7.35 37.5 KiB

    Loads all the time, even in page dflip NOT used. This is wrong, and means google will penalize the whole site if the plugin is installed.

    • This topic was modified 2 weeks, 6 days ago by mayy3321.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author DearHive

    (@dearhive)

    Hi,

    We have thought about this a lot of times. In fact we too think similarly. We too want to reduce the time and loading of the file.

    But the available solutions do not play well and we are still searching for a proper solution.

    1. Scanning for shortcodes in the content before adding the scripts: This is a common method, fails miserably when there is Ajax based content used in the site.
    2. Using iframe to display flipbooks instead of embedding: This is a method how YouTube displays videos. But then CSS customizations cannot be done.

    If we are able to get a solution that doesn’t have serious side effect we will add it. If this is a huge problem to you, we suggest you to try another plugin for time being.

    Best Regards,

    DearHive

    Thread Starter mayy3321

    (@mayy3321)

    I see. Well I think you can add an option button: Scanning for shortcodes in the content before adding the scripts

    If they use ajax, they turn it off.

    There, fixed for 98% cases for now.

    Several other Special feature type plug-ins have an option that says whether to use scripts on all pages or only where it’s used.

    • This reply was modified 2 weeks, 5 days ago by mayy3321.
    Plugin Author DearHive

    (@dearhive)

    Several other Special feature type plug-ins have an option

    Can you point out some, that you have experienced.

    • This reply was modified 2 weeks, 5 days ago by DearHive.

    In terms of a potential solution in the future, if the plugin used a block to output the viewer, then the script could only be loaded when the block is present. That combined with a new setting like “Improve site performance by not loading script unnecessarily (only supports dFlip block)” might work!

    Thread Starter mayy3321

    (@mayy3321)

    I can’t remember the exact plugins, I have trimmed down a lot now.

    But just simple checkbox

    on: js in all pages

    off: js only if detected

    Plugin Author DearHive

    (@dearhive)

    We have added an option in upcoming 2.1 Full version.

    View post on imgur.com

    Selective Script Loading : Load Scripts only on pages where shortcodes are added. May not work properly in AJAX based themes. Also clear your CACHE PLUGIN CACHE

    There are drawbacks. But since it disabled by default. Users will have an idea how it will work they change the option. We will improve on this as the feedbacks will star coming.

    • This reply was modified 2 weeks, 2 days ago by DearHive.
    • This reply was modified 2 weeks, 2 days ago by DearHive.
Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.