var isH5 = !! document.createElement('canvas').getContext
Would you say, that above JS code snippet is a good method of recognising a Browser's HTML5 capability?
Also see What is the !! (not not) operator in JavaScript? in case of IE quirks mode, it should still return false
.
Update: Thanks for all the Modernizr links, we are using above recognising logic in conjunction with Modernizr already.