Comments (7)
The only way to fix this it to preserve everything inside conditional comments
without changes. If there is no objections then I will go with this method.
Original comment by [email protected]
on 30 Aug 2010 at 6:03
- Changed state: Accepted
from htmlcompressor.
Could you treat everything inside them as a their own block which needs be
compressed and just leave these blocks wrapped in the conditional comments?
Original comment by [email protected]
on 30 Aug 2010 at 10:04
from htmlcompressor.
Fixed in 0.9.3 (using full compression inside).
Thanks.
Original comment by [email protected]
on 3 Sep 2010 at 5:08
- Changed state: Fixed
from htmlcompressor.
Awesome, working!
Minor nitpicking (run with remove-intertag-spaces):
Input portion:
</head>
<!--[if lt IE 7 ]> <body class="ie6 ie67"> <![endif]-->
<!--[if IE 7 ]> <body class="ie7 ie67"> <![endif]-->
<!--[!(IE)]><!--> <body> <!--<![endif]-->
<div>
Ideal output:
</head><!--[if lt IE 7 ]><body class="ie6 ie67"><![endif]--><!--[if IE 7
]><body class="ie7
ie67"><![endif]--><!--[!(IE)]><!--><body><!--<![endif]--><div>
Actual output:
</head> <!--[if lt IE 7 ]><body class="ie6 ie67"><![endif]--> <!--[if IE 7
]><body class="ie7 ie67"><![endif]--> <!--[!(IE)]><!--><body><!--<![endif]-->
<div>
There are 4 spaces that would ideally be removed.
Original comment by [email protected]
on 3 Sep 2010 at 7:29
from htmlcompressor.
will add to todo list, thanks.
Original comment by [email protected]
on 3 Sep 2010 at 3:18
- Changed state: Accepted
from htmlcompressor.
Excellent!
Just hit this bug and was happy to see it's already addressed. :D
We will be integrating the htmlcompressor into the html5boilerplate project for
the 1.0 release.
It's currently in development but its very exciting for us:
http://github.com/paulirish/html5-boilerplate/commits/build
Thanks Alastair and Sergiy!
Original comment by [email protected]
on 9 Sep 2010 at 2:17
from htmlcompressor.
Extra spaces around conditional comments are removed in 0.9.4
Original comment by [email protected]
on 13 Nov 2010 at 7:21
- Changed state: Fixed
from htmlcompressor.
Related Issues (20)
- a
- preserve-line-breaks causes StackOverFlow when consumed 2000 empty lines. HOT 1
- Velocity Version
- compressor replaces double spaces in urls and thus brokes the links HOT 1
- http://compilehtml.com/ not working anymore HOT 2
- javaScript wan't be compressed
- How to use the htmlcompressor? HOT 1
- [deleted issue]
- Unable to use latest closure compiler HOT 3
- how can i did not reduce spaces when it is in the input tag HOT 1
- removeSpacesInsideTags incorrectly removes space after some unquoted attributes HOT 1
- Unable to use closure HOT 2
- Extend HTML compressor to compress and combine external files
- Google Closure Compiler compiler.jar not found even though present
- one-line comment HOT 1
- styleTypeAttrPattern should also search for type="text/css"
- Add a --preserve-single-line-break option
- Update for JSP 2.2 HOT 2
- greedy simple attributes remove content for all attributes ending in "disabled" such as ng-disabled
- && in attributes breaks compression
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from htmlcompressor.