In xaml I can make whitespace relevant (that is not ignored) by using the xml:space attribute on a tag. Reference: http://msdn.microsoft.com/en-us/library/ms788720.aspx
Is there any way to make whitespace relevant in html?
Update:
Finally went with:
<p style="white-space: pre">
Hi This
is
an example
</p>
Although Aziz shaikh solution also works fine as well.
you can specify the white space property in css