sandbox.js 534 B

1234567891011121314151617181920
  1. /*!
  2. {
  3. "name": "iframe[sandbox] Attribute",
  4. "property": "sandbox",
  5. "tags": ["iframe"],
  6. "builderAliases": ["iframe_sandbox"],
  7. "notes": [
  8. {
  9. "name": "WHATWG Spec",
  10. "href": "https://html.spec.whatwg.org/multipage/embedded-content.html#attr-iframe-sandbox"
  11. }],
  12. "knownBugs": ["False-positive on Firefox < 29"]
  13. }
  14. !*/
  15. /* DOC
  16. Test for `sandbox` attribute in iframes.
  17. */
  18. define(['Modernizr', 'createElement'], function(Modernizr, createElement) {
  19. Modernizr.addTest('sandbox', 'sandbox' in createElement('iframe'));
  20. });