Friday, May 14th, 2010
- <audio>: return !!document.createElement(‘audio’).canPlayType;
- <device>: return ‘type’ in document.createElement(‘device’);
- <iframe sandbox>: return ‘sandbox’ in document.createElement(‘iframe’);
This also highlights how it would be nice to have a way to do CSS feature detection. In theory CSS is declarative, but in practice we are using it to do things like animations now, and we need a way to nicely degrade gracefully.
Anyway, thanks for yet another great resource, Mark.
Make sure to check out Modernizr as a tool that does this checking for you… as well as some CSS tests.
Posted by Dion Almaer at 11:19 am