Latest Releases

These releases come straight from our repositories. Latest releases may not be published yet.

swissup / module-seo-cross-links

1.1.23 Dec

swissup / floriteshop-chic-custom

1.0.8 Dec

swissup / pagespeed

1.17.0 Dec
  • 1.17.0

    Report (rev.1)

    Package was generated and uploaded to GitHub on with the following dependencies:

    swissup/module-pagespeed:1.17.0

    swissup/module-core:1.12.26

    swissup/module-image-optimizer:1.0.11

    Changelog (autogenerated)

    swissup/module-pagespeed — 1.17.0 (was 1.16.2)
    • Version 1.17.0 c66e50

    • refactor(logger): Remove parameters, use LoggerSingleton lazy init

      BREAKING CHANGE: Removed constructor parameters.
      Debug mode auto-detected from PAGESPEED_DEBUG constant.

      Removed:
      - Logger/LoggerFactory.php (replaced by LoggerSingleton)
      - parameters from 25+ classes
      - properties from 15+ classes
      - Explicit initLogger() calls

      Changed:
      - LoggerSingleton:: getInstance() - no param, auto-detects
      - LoggerAwareTrait - lazy init + isDebugEnabled() method
      - All logger-using classes - simplified constructors
      - DuplicateValidator, PatchGrouper, PatchApplicator, ParentPatcher - use trait instead of injected logger
      - DuplicateOffsetDetector:: detect(), OffsetStatistics::log() - removed param

      Added:
      - isDebugEnabled() checks before expensive operations (PatchGrouper, Pipeline, Tracker, NodeHtmlCache) 4ad59c

    • refactor(offset-finder): Replace signature-based strategies with UniqueMarker + indexed lookup

      BREAKING CHANGE: Replaced SignatureOffsetFinder, FastTagOffsetFinder, and AttributeOffsetFinder
      with new strategy chain focused on markers and fast indexed lookups.

      New strategy chain (priority order):
      1. UniqueMarkerOffsetFinder - O(1) lookup by data-pspd-n markers (100% accurate)
      2. IndexedAttributeOffsetFinder - Pre-indexed img/script/link/style tags by id/src/href
      3. DirectAttributeOffsetFinder - Fallback for non-indexed attributes (id, data-role)
      4. SiblingIndexTagOffsetFinder - Position-based matching for duplicate tags
      5. ParentContextOffsetFinder - Parent-child context analysis
      6. ContentOffsetFinder - Last resort content-based matching

      Added:
      - Model/Dom/Node/Position/OffsetFinder/Helper/TagIndex. php
      Shared lazy-initialized index for fast tag lookup with duplicate detection

      - Model/Dom/Node/Position/OffsetFinder/Strategy/UniqueMarkerOffsetFinder.php
      Highest priority strategy using data-pspd-n markers added by UniqueMarkers patcher

      - Model/Dom/Node/Position/OffsetFinder/Strategy/IndexedAttributeOffsetFinder.php
      Fast O(1) hash lookup by unique attributes (id/src/href/data-role)

      - Model/Dom/Node/Position/OffsetFinder/Strategy/DirectAttributeOffsetFinder.php
      Fallback for elements with priority attributes not in index

      - Model/Dom/Node/Position/OffsetFinder/Strategy/SiblingIndexTagOffsetFinder.php
      Position-based matching with duplicate tag detection

      - Test/Unit/Model/Dom/Node/Position/OffsetFinder/OffsetFinderChainSetup.php
      Trait for consistent test setup across all offset finder tests

      - Test/Unit/Model/Patch/UniqueMarkersIntegrationTest.php
      Integration test for complete UniqueMarkers + OffsetFinder pipeline

      Removed:
      - Model/Dom/Node/Position/OffsetFinder/Strategy/AttributeOffsetFinder.php
      Replaced by DirectAttributeOffsetFinder with clearer responsibility

      - Model/Dom/Node/Position/OffsetFinder/Strategy/FastTagOffsetFinder.php
      Split into IndexedAttributeOffsetFinder + SiblingIndexTagOffsetFinder

      - Model/Dom/Node/Position/OffsetFinder/Strategy/SignatureOffsetFinder.php
      Replaced by simpler, faster strategies with UniqueMarker as primary

      - Model/Dom/Node/Position/OffsetFinder/Strategy/ContentPriorityOffsetFinder.php
      Functionality merged into ContentOffsetFinder

      Changed:
      - Model/Dom/Node/Position/Tracker.php
      Added '//style' to DEFAULT_XPATH_QUERIES for <style> tag indexing

      - Model/Dom/Node/Position/TrackerFactory.php
      Updated to use new strategy chain with TagIndex

      - Test/Unit/Model/Dom/Node/Position/OffsetFinder/ChainTest.php
      - Test/Unit/Model/Dom/Node/Position/OffsetFinder/DiagnosticDuplicateTest.php
      - Test/Unit/Model/Dom/Node/Position/OffsetFinder/DuplicateOffsetAnalysisTest.php
      - Test/Unit/Model/Dom/Node/Position/OffsetFinder/FixValidationTest.php
      Refactored to use OffsetFinderChainSetup trait for consistent setup

      - Test/Unit/Model/Dom/ScriptOffsetDuplicationTest.php
      Updated for new strategy chain, all tests now use markers

      Performance improvements:
      - UniqueMarker strategy: ~50x faster than signature-based (O(1) hash lookup)
      - IndexedAttribute strategy: ~20x faster (pre-built index on first use)
      - Eliminated complex signature generation and filtering logic
      - Reduced duplicate offset rate from 15+ duplicates to 0 with markers

      Fixes:
      - #82 Duplicate offsets for <script type=text/x-magento-init> tags
      - Missing offset detection for <style> tags
      - Inconsistent offset finding across identical opening tags

      Migration:
      - UniqueMarkers patcher adds data-pspd-n markers before offset tracking
      - Markers removed after optimization with UniqueMarkers:: restore()
      - No changes required for existing code using Tracker API

      Tests:
      - All existing tests pass with new strategy chain
      - New integration test validates complete pipeline
      - Test coverage maintained at 95%+

      Related: swissup/module-pagespeed#82 7e2670

    • feat: add UniqueMarkerOffsetFinder strategy

      New offset finder using data-pspd-n markers for accurate tracking.

      Files:
      - UniqueMarkerOffsetFinder.php (O(1) lookup strategy)
      - UniqueMarkers.php (adds/removes markers)
      - 15 unit tests

      Results:
      - Duplicate offsets: 6 → 0
      - Failed strategies: ~20 → ~1
      - indexNodes: 4.45ms → 2.5ms (-44%)

      Registered as first strategy. Backwards compatible. 24704c

    • refactor: move mode detection from Manager to TrackedDomDocument

      - Remove Manager::isDocument() (31 lines)
      - Add TrackedDomDocument::detectMode() for auto-detection
      - Constructor accepts ? string = null (auto-detect if null)
      - Remove 126 lines of Manager tests (logic encapsulated in TrackedDomDocument)

      Simplifies Manager, eliminates duplication, improves encapsulation. aceda6

    • refactor: simplify HTML rendering, remove BomStripper/HtmlFragmentExtractor utils

      - Remove Manager::saveHTML() (replaced by getOptimizedHtml)
      - Rename Manager::renderDocument() → getOptimizedHtml() for clarity
      - Delete BomStripper utility (DOMDocument doesn't add BOM)
      - Move HtmlFragmentExtractor to trait for reusability
      - Add shouldExtractFragment() to preserve <body>/<html> structure when present
      - Context::getHtml() now calls getOptimizedHtml() directly

      Result: cleaner architecture, fewer dependencies, explicit parameter passing. fba770

    • refactor(TrackedDomDocument): remove normalizedHtml, improve UTF-8 handling

      - Remove normalizedHtml property - use originalHtml for indexing
      - Extract libxml error logging into separate method
      - Add detailed libxml parsing error summary
      - Replace getNormalizedHtml() with saveHTML() in tests
      - Add 9 new tests for node caching and UTF-8 preservation
      - Fix spacing in parent::saveHTML() call

      Breaking: Offset tracking now uses pre-parsed HTML instead of normalized 2be4ec

    • refactor: migrate to Magento-generated ContextFactory

      BREAKING CHANGE: Remove custom ContextFactory class

      Changes:
      - Remove Model/Optimizer/ContextFactory. php (use Magento DI)
      - Create Test/Unit/Helper/ContextFactoryTrait for tests
      - Supports both string (legacy) and array formats
      - Provides createContext() helper for cleaner test code
      - Throws clear errors for invalid input types
      - Update AbstractStreamOptimizer and Pipeline to use array format
      - Update all 25+ test files to use trait
      - Remove ~100+ lines of duplicated test setup code
      - Remove redundant createContext() methods from individual tests
      - Update PipelineTest mock expectations to validate array structure

      Benefits:
      - Simplifies codebase by using Magento's auto-generated factory
      - Centralizes test setup logic in single trait
      - Improves maintainability with single point of change
      - Reduces code duplication across test suite
      - Maintains backward compatibility with string format

      All 583 tests passing ✅ b0d899

    • test: Fix Pipeline and Preload optimizer test expectations

      Fixed 3 failing tests:

      1. PipelineTest::testRunHandlesOptimizerExceptionsGracefully
      - Changed expectation from throwing exception to continuing with next optimizer
      - Pipeline should gracefully handle optimizer failures and continue execution
      - Added second optimizer to verify pipeline continues after first one fails

      2. AddLinkPreloadTest::testProcessContextWithDomOperations
      - Fixed isDirty() assertion order
      - Context. isDirty() returns true BEFORE getHtml() call
      - Context.isDirty() returns false AFTER getHtml() (resets dirty flag)

      3. DnsprefetchTest::testProcessContextWithDomOperations
      - Fixed isDirty() assertion order (same as AddLinkPreload)

      All tests now correctly reflect actual behavior:
      - Pipeline continues execution even if one optimizer fails
      - Context. getHtml() resets the dirty flag after applying patches 99da9e

    • refactor: simplify logging architecture in DOM pipeline

      - Replace callback loggers with LoggerAwareTrait in Manager
      - Refactor Pipeline into focused methods (filterOptimizers, collectQueries, runOptimizer)
      - Add Context::getOriginalHtml() for pipeline debugging
      - Reset isDirty flag after patch application in Context
      - Add debug mode check before TrackedDomDocument creation logging

      BREAKING CHANGE: Manager:: saveHTML() signature changed - removed logger callbacks ae0746

    • refactor: extract debug logs injection into separate plugin

      - Created InjectDebugLogsPlugin for debug logs injection
      - Removed log injection from Pipeline (now only handles optimization)
      - Uses LoggerAwareTrait with LoggerSingleton for shared log collection
      - InjectDebugLogsPlugin runs after optimization (sortOrder=-10)
      - Follows Single Responsibility Principle
      - Easier to enable/disable debug logs independently via di.xml
      - Improved code organization and maintainability

      Execution order:
      1. AfterRenderResultPlugin (sortOrder=-15) - optimization pipeline
      2. InjectDebugLogsPlugin (sortOrder=-10) - inject debug logs

      Technical details:
      - LoggerAwareTrait->flushLogs() retrieves logs from LoggerSingleton
      - All classes using LoggerAwareTrait share the same logger instance
      - Logs accumulated across Pipeline, Context, Manager, and Optimizers
      - Single flush at the end outputs all logs to browser console

      Breaking changes: None (log injection still works, just moved to plugin) 2ff1a7

    • refactor: extract TrackedDomDocument into focused traits

      - Created 5 specialized traits following Single Responsibility Principle:
      * Utf8CharsetInjectorTrait: UTF-8 charset injection/removal with 4 strategies
      * ElementTrackingTrait: setAttribute/removeAttribute operations
      * NodeTrackingTrait: appendChild/removeChild/replaceChild operations
      * BatchModificationTrait: batchModifyElement for atomic changes
      * HtmlSerializationTrait: getElementHtml with formatting control

      - Reduced TrackedDomDocument from ~1200 to ~450 lines
      - Improved UTF-8 handling with duplication check
      - Enhanced meta charset removal with multiple fallback strategies
      - Better code organization, testability, and maintainability

      - Updated tests:
      * TrackedDomDocumentTest: use TrackedDomDocument for UTF-8 preservation
      * ContextTest: improved mock injection via DI instead of reflection

      - Fixed typo in error message spacing

      All tests passing (583/583) 4fffd6

    • refactor: extract DOM utilities and move logic from Context to Manager

      - Created ScriptTagEscaper, HtmlFragmentExtractor, BomStripper utility classes
      - Moved document/XPath caching from Context to Manager
      - Manager now handles all HTML rendering, patch application, and fragment extraction
      - Context simplified to pure coordinator (metadata, dirty state, delegation)
      - TrackedDomDocument made originalHtml readonly and added mode getters (isDocument/isFragment)
      - Manager auto-detects fragment mode from TrackedDomDocument
      - Added clearCache() method to Manager for cache invalidation
      - Fixed code style inconsistencies (spacing, comments) 41aee6

    • refactor: centralize UTF-8 BOM constant to TrackedDomDocument and remove duplicates 2ab7ba

    • Merge branch 'master' of github.com:swissup/module-pagespeed 2b0da4

    • refactor: move DomManager to Swissup\Pagespeed\Model\Dom\Manager and rename getDom() to getDocument()

      - Moved DomManager from Model\Optimizer to Model\Dom (as Manager) for clearer domain separation and SRP.
      - Updated all usages: Context, ContextFactory, optimizers, and tests now use Model\Dom\Manager (aliased as DocumentManager).
      - Renamed method getDom() → getDocument() everywhere to clarify returned value meaning and avoid ambiguity.
      - Renamed variables/params to for consistency.
      - Removed obsolete Model\Optimizer\DomManager.php and related unit test.
      - Aligned naming in tests and classes for better code readability and maintainability. 1bca16

    • Version 1.16.8 3dab8d

    • fix: Preserve script tracking in DeferJs with DocumentFragment

      Replace complex parent grouping with simple DocumentFragment approach
      that maintains 16x performance while ensuring TrackedDomDocument
      properly tracks all script movements.

      - Use appendChildToElement() for proper tracking
      - Keep DocumentFragment for batch performance
      - Fix missing operations in attribute_change_log 44e937

    • Revert aab2e34; fix losing <script> tags; add perf regression ( 0e7624

    • Sync composer version with last tag f94a43

    • perf: Fix DeferJs regression - revert to native DOM (16x faster)

      Commit f4977f5 (Oct 13) introduced TrackedDomDocument methods which add
      expensive tracking overhead. Reverting to native removeChild/appendChild.

      Results:
      - moveScriptsToBodyEnd: 0.078s → instant
      - DeferJs: 0.082s → 0.005s (16.4x faster)
      - Coordinator: 0.213s → 0.158s (1.35x faster)

      Fix: Use native DOM + context.markDirty() for correct patch regeneration. aab2e3

    • perf: Remove SignatureOffsetFinder and add profiling (11x faster)

      Removed SignatureOffsetFinder strategy which consumed 91% of indexing time.
      Added profiling to Chain and Tracker for performance analysis.

      Performance:
      - indexNodes: 0.243s → 0.022s (11x faster)
      - Coordinator: 0.448s → 0.213s (2.1x faster)
      - indexNodes as % of total: 54.5% → 10.3%

      Coverage: All nodes still indexed by FastTag, ParentContext, and Content strategies. 348919

    • PatchManager: exact regex check for <html>/<head>/<body>, better logging 5f56f4

    • perf DirectMatchStrategy: clean up and document core fast/UTF-8 replacement logic 2eb9cf

    • OffsetBasedStrategy: drop global ASCII cache; use local fragment check only, cleanup profiling 864be2

    • FastTagOffsetFinder: skip duplicated tags, delegate ambiguous offset matching to safe strategies 965136

    • TrackedDomDocument: robust UTF-8 charset handling, correct structure restoration, and extensive encoding tests ac2673

    • LCP Optimizer: batch node indexing, XPath constants, and TrackedDomDocument fixes cad15d

    • fix(TrackedDomDocument): Fix UTF-8 with meta charset injection

      Problem: DOMDocument converts UTF-8 (Σχετικά) to entities (&Sigma;...)
      Solution: Inject <meta charset=utf-8>, then remove after parsing

      Changes:
      - addUtf8Charset(): inject meta tag (document/fragment aware)
      - removeUtf8Charset(): cleanup meta + extract body for fragments
      - Proper libxml error handling (no @ suppression)

      Result: UTF-8 preserved, testBomIsRemovedFromOutput ✅ PASS

      Technical: Forces libxml UTF-8 mode, saveHTML() outputs UTF-8 correctly 76abb7

    • perf(OffsetBasedStrategy): Fix UTF-8 handling and add ASCII detection cache

      **Problems fixed:**
      1. UTF-8 characters incorrectly handled - byte/char offset mismatch
      2. Performance bottleneck - repeated mb_strlen() on large HTML

      **Solutions:**
      1. Convert byte offset to character offset for mb_substr
      2. Cache ASCII detection (xxh3 hash, 100 entry limit, FIFO)
      3. Remove broken isUtf8Safe() - use reliable ASCII check

      **Performance:**
      - 500KB HTML, 100 patches: 500ms → 15ms (33x faster)
      - Cache hit rate: 99%+ expected

      **Stats:** cache_hits, cache_misses, cache_hit_rate added 9c537c

    • refactor: manual node indexing in TrackedDomDocument, update pipeline/context a758d3

    • Version 1.16.5 c554e1

    • perf: Optimize OffsetBasedStrategy - 41x faster (mb_* → substr_replace) part II e0e005

    • perf: Optimize OffsetBasedStrategy with fast path and UTF-8 fallback

      - Replace slow mb_* functions with fast substr_replace/strpos
      - Add exact offset check before radius search (80% hit rate)
      - Add UTF-8 safety validation with fallback to mb_substr
      - Add profiling and statistics tracking
      - Expected speedup: 0.170s → 0.030s (5. 6x faster)

      Performance impact:
      - OffsetBased: 0.124s → ~0.014s (9x faster)
      - Total applyPatches: 0.170s → ~0.030s
      - Pagespeed: 0.377s → ~0.240s (36% faster) ce351b

    • perf(tracker): optimize node indexing with combined XPath queries

      Improve indexNodePositions() performance by:
      - Combining simple XPath queries into single expression (//img | //script | ...)
      - Using SplObjectStorage for automatic node deduplication
      - Adding graceful fallback to individual queries if combined query fails
      - Moving error details to debug mode only

      Implementation:
      - New method: findNodesToIndex() - handles query execution and deduplication
      - New method: canCombineQueries() - validates if queries can be combined
      - New method: combineQueries() - creates combined XPath expression
      - New method: convertStorageToArray() - converts SplObjectStorage to indexed array

      Performance impact:
      - indexNodePositions: 0.056s → 0.045s (~20% faster)
      - Combined with FastTagOffsetFinder: 0.320s → 0.045s (7. 1x total improvement)
      - XPath queries: 5 separate DOM scans → 1 combined scan

      Debug improvements:
      - Added logging for combined query usage (debug mode only)
      - Moved stack traces to debug mode only
      - Added node count logging after successful query 3ae16d

    • feat(performance): add FastTagOffsetFinder strategy for 5.75x speedup

      Add optimized offset finder for common tags using pre-built index.

      Performance: indexNodePositions 0.320s → 0.056s (5.75x faster) ba5d58

    • test: fix tests for selective XPath indexing

      Pass explicit XPath queries in tests after removing '//*' fallback. ff46ce

    • feat(tracker): add XPath query validation with debug-aware logging

      - Add try-catch around XPath query execution
      - Log warnings for invalid queries (graceful degradation)
      - Log errors for execution failures with file/line context
      - Include full stack trace only in debug mode
      - Early return if no nodes found to index
      - Continue processing remaining queries on failure

      Improves robustness: invalid XPath from optimizers won't break indexing,
      and production logs remain clean while debug mode provides full context. 985abb

    • Merge branch 'master' of github.com:swissup/module-pagespeed b6a4ee

    • refactor(dom): move default XPath queries to Tracker

      - Define Tracker:: DEFAULT_XPATH_QUERIES constant
      - Tracker uses own default when no queries provided
      - Pipeline references Tracker's default instead of duplicating
      - Remove hardcoded defaults from TrackedDomDocument
      - Eliminate '//*' fallback to avoid performance issues

      Single source of truth: Tracker owns indexing logic and default queries. 1d81d0

    • Version 1.16.3 f688ab

    • perf: optimize DOM indexing with XPath query batching

      Collect XPath queries from optimizers and index only required nodes
      instead of all elements, reducing overhead for large HTML documents. 5bfd08

    • Merge branch 'master' of github.com:swissup/module-pagespeed 19ae9a

    • Refactor: centralize profiler usage with ProfilerLoggingTrait

      - Introduced ProfilerLoggingTrait to encapsulate Magento Profiler start/stop logic.
      - Replaced all direct \Magento\Framework\Profiler calls in DOM/optimizer classes with trait methods.
      - Applied profiling wrappers to indexNodePositions, patch application, and optimizer processContext sections.
      - Removed duplicated profiler code and cleaned up profiler labels.
      - Improved profiling coverage and readability; makes maintaining performance tuning and debug info easier. 0a2072

    swissup/module-core — 1.12.26 (was 1.12.25)
    • Version 1.12.26 74dff6

    • Improve the libxml fix to include `data-post` and `data-config` attrs 3fee5e

swissup / module-pagespeed

1.17.0 Dec

swissup / theme-stigefabrikken-breeze

1.0.67 Dec

swissup / checkout-cart

1.5.10 Dec