diff --git a/CHANGES.rst b/CHANGES.rst index d965b51e..1d1350aa 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -16,10 +16,10 @@ pywb 2.0.5 changelist - Optimized argument de-proxying in wombat (#385) - Improved iframe srcdoc rewriting in wombat (#386) -* Image srcset and media query preservation system (#359, #379, #378): +* Image srcset and media query auto-fetch system (#359, #379, #378): - Added image srcset and media query preservation system to wombat - - Added ``proxy-with-wombat`` option, if true, enables the usage of ``wombatProxyMode.js`` in proxy mode (default: false) - - Added ``proxy-with-auto-fetch`` option, if true, enables the usage of ``autoFetchWorkerProxyMode.js`` in proxy mode (default: false) + - Added ``--proxy-enable-wombat`` cli flag; if set, enables the usage of ``wombatProxyMode.js`` in proxy mode (default: false) + - Added ``--enable-auto-fetch`` cli flag; if set, enables the usage of auto fetch web worker in both url rewrite and proxy modes (default: false) - Added ``FrontEndApp.proxy_fetch()`` to allow the auto fetch worker to request cross-origin style sheets * Fuzzy Matching: @@ -31,8 +31,10 @@ pywb 2.0.5 changelist * Server-Side Rewriting: - Refactored the regular expression rewriters in-order to avoid multiple initialization (#354) - Improved unicode URL rewriting (#361, #376, #377, #380) - - Improved cookie rewriting (#386) + - Improved cookie rewriting in framed replay mode (#386) - Improved handling of bad content-length HTTP header (#386) + - Fix parsing of self-closing diff --git a/pywb/templates/head_insert.html b/pywb/templates/head_insert.html index 12a45e0e..b1fe7f59 100644 --- a/pywb/templates/head_insert.html +++ b/pywb/templates/head_insert.html @@ -24,17 +24,14 @@ wbinfo.coll = "{{ coll }}"; wbinfo.proxy_magic = "{{ env.pywb_proxy_magic }}"; wbinfo.static_prefix = "{{ static_prefix }}/"; -{% if env.pywb_proxy_magic %} - wbinfo.use_auto_fetch_worker = {{ config.proxy.use_auto_fetch_worker | tobool }}; - wbinfo.use_wombat = {{ config.proxy.use_wombat | tobool }} || wbinfo.use_auto_fetch_worker; -{% endif %} + wbinfo.enable_auto_fetch = {{ config.enable_auto_fetch | tobool }}; {% if env.pywb_proxy_magic %} {% set whichWombat = 'wombatProxyMode.js' %} {% else %} {% set whichWombat = 'wombat.js' %} {% endif %} -{% if not wb_url.is_banner_only or (env.pywb_proxy_magic and (config.proxy.use_auto_fetch_worker or config.proxy.use_wombat)) %} +{% if not wb_url.is_banner_only or (env.pywb_proxy_magic and (config.enable_auto_fetch or config.proxy.enable_wombat)) %}