• Resolved christoph-ED

    (@webagenturerding)


    I install the plugin and even if i dont use any block i see gewid add js and css files … also for slick what i dont want to use.

    Is there any way to fix this?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Contributor motopress

    (@motopress)

    @webagenturerding could you share a link?

    Plugin Support dimned

    (@dimned)

    Hi @webagenturerding,
    We have just released a new version of Getwid 1.5.3 where we stopped loading assets if the blocks are not used. Please update the plugin to get this enhancement.
    It would be much helpful if you rate Getwid plugin https://www.ads-software.com/support/plugin/getwid/reviews/ Thanks.

    Hello @dimned it’s a good idea not to load the plugin if you don’t use it, but I’m making use of getwid blocks through custom templates. Is there any way to reload the plugin? I’ve encountered the problem that I have files, singles, cpt, 404, broken because I add a block above the footer and another one below the header.
    Thank you very much.

    Plugin Support dimned

    (@dimned)

    Hi @iescuer,
    Thank you for your reply. You may try to use add this filter to load the proper assets add_filter( 'getwid/blocks/has_block', '__return_true' ); or you can get the previous version of the plugin here https://www.ads-software.com/plugins/getwid/advanced/
    We will review the possible solutions for your case in further updates. Thanks

    alexandermatienkogmailcom

    (@alexandermatienkogmailcom)

    We had to roll back the update related to optimizing assets loading released in Getwid version 1.5.3 for the following reasons:

    1. So far there is no 100% accurate method to identify that the block that requires assets is displayed on the page. You can find more examples and case studies on this forum.
    2. The optimization might not work properly in case a block is a reusable one since the content of a reusable block is within another post.
    3. There is no evidence that block-based themes can properly handle this optimization; to wit, when blocks are used in the header, footer, or widget zones.
    4. If there is a block that displays any posts on a page, we can’t effectively recognize the content of these posts until they are painted on a page.

    One more limitation that holds us back from this optimization is that CSS styles of the blocks are loaded before style.css of your theme to ensure the blocks can blend with the theme styles.

    However, in Getwid version 1.5.4 we managed to minimize the total size of the loaded assets compared to the previous plugin versions. Don’t forget that you can disable unneeded Getwid blocks to improve the performance.

    An empty page contains 6 assets, 210 kB in total (which is twice as less than in the previous version). You as a developer can also control how many assets to load by enabling/disabling individual or all assets in each particular case.
    Follow this link below to examine the example we’ve created for you
    https://gist.github.com/mototeam/34b4ef0cb4f4ff4ff4d3c8a5f9a5cafe

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Dont load blocks if not ins use ?’ is closed to new replies.