The reason is simple: In HTML documents, multiple whitespace characters are equivalent to one whitespace character. In other words, it is unsafe to delete whitespace characters such as line breaks, as this may cause differences in the styles of some elements. In HTML elements, there is a pre, which means preformatted text. Any whitespace inside it cannot be deleted. It is possible to have IE conditional comments in HTML. These conditional comments are part of the document logic and cannot be removed. I only think of the above 3 points, there may be other pitfalls. For dynamic pages, HTML compression may increase the CPU burden on the server, which is not worth the cost. Generally speaking, gzip compression can achieve good results. There are pitfalls to further compression, and unless you have tested it as thoroughly as Google has (Google only compresses a small number of core service pages), it is not recommended to compress HTML. |
<<: Detailed explanation of JavaScript timers
>>: Solutions to invalid is Null segment judgment and IFNULL() failure in MySql
Make a nice flip login and registration interface...
The default number of remote desktop connections ...
Table of contents Create a vue + ts project using...
This article example shares the specific code of ...
Preface I wrote a small demo today. There is a pa...
Anyone who has used the Linux system should know ...
If you think the system is slow and want to chang...
To improve the performance of web pages, many dev...
Table of contents What to do when registering an ...
Scenario: An inspection document has n inspection...
Use HTML to create complex tables. Complex tables...
Table of contents 1 Test Environment 1.1 Server H...
This article mainly introduces the solution to th...
Table of contents Application Scenario Ideas Proj...
This article example shares the specific code of ...