Skip to content

Commit

Permalink
Update: adding a defaultView to the shadow root
Browse files Browse the repository at this point in the history
  • Loading branch information
stevematney committed Mar 31, 2020
1 parent 34c89a5 commit f389fa9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/ReactHTMLElement.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ interface LooseShadowRoot extends ShadowRoot {
function retargetReactEvents(container: Node, shadow: LooseShadowRoot): void {
Object.defineProperty(container, 'ownerDocument', { value: shadow });
/* eslint-disable no-param-reassign */
shadow.defaultView = window;
shadow.createElement = (
tagName: string,
options?: ElementCreationOptions,
Expand Down

0 comments on commit f389fa9

Please sign in to comment.