Plugin Directory


Ignore:
Timestamp:
11/08/2026 04:28:35 PM (less than one hour ago)
Author:
degird
Message:

Release 1.2.4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cliedesk/trunk/src/Modules/Widget/WidgetModule.php

    r3787995 r3791202  
    936936                        return;
    937937                }
     938                // The page carries the public config: a cached copy is refreshed when the settings change.
     939                \Cliedesk\Infrastructure\Http\NoCache::tag_public();
    938940                wp_enqueue_script(
    939941                        'cliedesk-widget',
    … …  
    953955                                        return $tag;
    954956                                }
    955                                 // The public config travels with the script: no extra request on the site itself.
    956                                 return str_replace( ' src=', ' data-config="' . esc_attr( (string) wp_json_encode( $config ) ) . '" src=', $tag );
     957                                // The public config travels with the script: no extra request on the site itself. The loader finds that
     958                                // config through its own tag, so an optimizer must not merge or delay it (LiteSpeed Cache: these attributes).
     959                                return str_replace( ' src=', ' data-no-optimize="1" data-no-defer="1" data-config="' . esc_attr( (string) wp_json_encode( $config ) ) . '" src=', $tag );
    957960                        },
    958961                        10,
Note: See TracChangeset for help on using the changeset viewer.