In this case I applied a mix of the Principle of core content and the Principle of readability to the decision to put the value in content and the units in an attribute.
You can focus on your core business requirements and mix in the additional functionality you need - searching, authentication, alternate presentation layers, and more - from external resources.