This project is read-only.

Whitespace removal not working on postback

Apr 26, 2010 at 5:13 PM

Thank you for this project, I think this is a very useful effort at providing a simple and integrated set of optimization tools. I've been following your posts on your blog about removing whitespaces, and I have stumbled across this new project of yours thanks to your latest post on Twitter.

I've given it a try and I have a question. Why are you only removing whitespaces on GET? Postbacks produce a POST and whitespaces are not removed in this case. For now I've recompiled without the GET condition but I don't know what else I'm breaking. It would be quite useful to strip whitespaces in this case as well.

Additionally, I want to state that removing whitespaces is not ONLY a performance choice. It is also a design choice. In some cases, the generated HTML contains whitespaces and this might have undesired visual effects. For example a whitespace between 2 buttons. Many times you just don't have the possibility of removing that whitespace before-hand, and using an HttpModule is the only solution.

Thanks for your help.