Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const { JSDOM } = require('jsdom-wc');
const { window } = new JSDOM('');
// function copyProps(src, target) {
// Object.defineProperties(target, {
// ...Object.getOwnPropertyDescriptors(src),
// ...Object.getOwnPropertyDescriptors(target),
// });
// }
// Object.assign(global, {
// document: window.document,
// HTMLElement: window.HTMLElement,
// customElements: window.customElements,
// window: window
// });
global.document = window.document;
const { JSDOM } = require('jsdom-wc');
const { window } = new JSDOM('');
// function copyProps(src, target) {
// Object.defineProperties(target, {
// ...Object.getOwnPropertyDescriptors(src),
// ...Object.getOwnPropertyDescriptors(target),
// });
// }
// Object.assign(global, {
// document: window.document,
// HTMLElement: window.HTMLElement,
// customElements: window.customElements,
// window: window
// });
global.document = window.document;