Oliver Klee
Oliver Klee
This parser looks quite promising: https://github.com/tbela99/css It requires PHP >= 8.0, though.
… using the tool "alex" like Symfony has done: https://alexjs.com/ https://github.com/symfony/symfony-docs/pull/14215/files
https://github.com/rectorphp/rector is a tool that automatically can do PHP language level upgrades. The TYPO3 project already uses it with great success.
To work on improving performance, we need benchmarks to check whether a change helps. I propose we benchmark these things: - the same `CssInliner` instance with the same HTML and...
We probably can improve performance if we share some caches between `CssInliner` instances. We need to safeguard this with tests.
In addition to the small architectural problems (`CssInliner` is too big and does too much, arrays and `stdClass` instead of dedicated classes), I currently see two big problems I'd like...
We should move the CSS parsing either to a separate class or use an existing package for this, e.g. one of these: - https://packagist.org/packages/sabberworm/php-css-parser - https://packagist.org/packages/soloproyectos-php/css-parser
@vanderlee Would you be willing to provide a performance testcase for this with some (bigger) real-world-like data?