• Resolved Frederic

    (@frederichesse)


    Hello,

    first of all I would like to mention that this plugin is the only plugin of this type that we have managed to get running in our customer’s environment. And the option to remove certain files from the merge process alone is a great blessing, which has saved us many problems. So thank you very much for this helpful plugin.

    But unfortunately we have a small problem with the plugin. We provide our own CSS and JS files with a timestamp to version them and to avoid problems with the caching of browsers. But we have a JS file that we exclude from the merge process because it is not fully compatible with it. Unfortunately, when using this plugin, the question mark with the timestamp is removed from this file. This leads to the browser of users not recognizing changes within the file.

    Is there a workaround for this problem or is this perhaps a “bug” in the plugin. Many thanks for any help in advance.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author launchinteractive

    (@launchinteractive)

    Hi Frederic,

    Are you able to provide the url you are using and the wp_enqueue code you are using enqueue it? I will then test it at my end.

    Thread Starter Frederic

    (@frederichesse)

    Hello,

    many thanks for the quick reply and sorry for my late reply. Unfortunately, I have not been in the office for the last few days.

    Below is the code snippet for embedding the JS file in question

    function mfnch_enqueue_styles() {
    // Webpack-generated assets
    wp_enqueue_style('betheme-child-main', get_stylesheet_directory_uri() . '/dist/main.bundle.css', [], filemtime(__DIR__.'/dist/main.bundle.css'));
    wp_enqueue_script('betheme-child-main', get_stylesheet_directory_uri() . '/dist/main.bundle.js', [], filemtime(__DIR__.'/dist/main.bundle.js'), true);
    }

    And more information in the following screenshot: Plugin Config | Exclude the file in question | And the URL:

    The file in the frontend when the plugin is deactivated:

    The file in the frontend when the plugin is activated:

    I hope this helps for further testing. Many thanks in advance.
    Frederic

    • This reply was modified 8 months, 2 weeks ago by Frederic.
    Thread Starter Frederic

    (@frederichesse)

    Note: We use version 2.8 of the plugin

    Plugin Author launchinteractive

    (@launchinteractive)

    Thanks Frederic. This has been fixed with version 2.9.
    I will mark this as resolved.

    Thread Starter Frederic

    (@frederichesse)

    I have just cross-checked it. It works perfectly for us. Many thanks for the quick support.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Timestamp / Version of file is removed for excluded files’ is closed to new replies.