• Robert Knight's avatar
    Switch to using `<link>` elements for stylesheets in shadow DOM · 1d2eaf68
    Robert Knight authored
    When Shadow DOM was first considered for use in the client `<link
    rel="stylesheet">` was not widely supported as a way to load external styles into
    shadow roots. This was resolved in the spec in https://github.com/whatwg/html/pull/1572
    and has now long been supported by all browsers.
    
    Using `<link>` simplifies the code and also avoids a possible problem with sites
    that have a strict CSP policy that disallows inline styles. In the
    browser extension context a `<link>` can still work in that scenario as long as the
    stylesheet is loaded from a `chrome-extension://` URL.
    1d2eaf68
Name
Last commit
Last update
..
test Loading commit data...
buckets.js Loading commit data...
frame-util.js Loading commit data...
shadow-root.js Loading commit data...
url.js Loading commit data...