Skip to content

Commit

Permalink
fix: add better comment
Browse files Browse the repository at this point in the history
  • Loading branch information
nolanlawson committed May 10, 2022
1 parent 3c63e5f commit 165663a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/@lwc/engine-dom/src/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ const isIE11 = !isUndefined((document as any).documentMode);

// Global cache of style elements used for fast cloning
let styleElements: Map<string, HTMLStyleElement> = new Map();
// Global cache of CSSStyleSheets because these need to be unique based on content
// Global cache of CSSStyleSheets because these need to be unique based on content so the browser
// can optimize repeated usages across multiple shadow roots
let stylesheets: Map<string, CSSStyleSheet> = new Map();
// Bookkeeping of targets to CSS that has already been injected into them, so we don't duplicate
let shadowRootsToInsertedStylesheets: WeakMap<ShadowRoot, Set<string>> = new WeakMap();
Expand Down

0 comments on commit 165663a

Please sign in to comment.