voku/HtmlMin

Not all whitespace in <pre> tags is preserved

ozupey opened this issue · 1 comments

What is this feature about (expected vs actual behaviour)?

While spaces and tabs are preserved, newlines inside <pre> tags are gone.

string(23) "<pre>foo	bar		zoo</pre>"

How can I reproduce it?

$html = '<pre>
foo
        bar
                zoo
</pre>';

$htmlMin = new voku\helper\HtmlMin();
$result = $htmlMin->minify($html);

var_dump($result);

Does it take minutes, hours or days to fix?

Unsure

Any additional information?

Using 3.1.3 installed via composer on PHP 7.2.10.

voku commented

fixed in version 3.1.5