* @param {!Window} win * @return {boolean}
(win)
| 317 | * @return {boolean} |
| 318 | */ |
| 319 | function calcShadowDomStreamingSupported(win) { |
| 320 | // API must be supported. |
| 321 | if ( |
| 322 | !win.document.implementation || |
| 323 | typeof win.document.implementation.createHTMLDocument != 'function' |
| 324 | ) { |
| 325 | return false; |
| 326 | } |
| 327 | // Firefox does not support DOM streaming. |
| 328 | // See: https://bugzilla.mozilla.org/show_bug.cgi?id=867102 |
| 329 | if (Services.platformFor(win).isFirefox()) { |
| 330 | return false; |
| 331 | } |
| 332 | // Assume full streaming support. |
| 333 | return true; |
| 334 | } |
| 335 | |
| 336 | /** |
| 337 | * Creates the Shadow DOM writer available on this platform. |
no test coverage detected