typed-dom
Advanced tools
Comparing version 0.0.337 to 0.0.338
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -68,6 +68,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -77,3 +94,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -126,2 +143,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -138,3 +156,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -141,0 +159,0 @@ exports.shadow = shadow; |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object') |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -256,6 +256,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -265,3 +282,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -1068,2 +1085,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -1080,3 +1098,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -1083,0 +1101,0 @@ exports.shadow = shadow; |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object') |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -256,6 +256,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -265,3 +282,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -1068,2 +1085,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -1080,3 +1098,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -1083,0 +1101,0 @@ exports.shadow = shadow; |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object') |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -68,6 +68,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -77,3 +94,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -126,2 +143,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -138,3 +156,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -141,0 +159,0 @@ exports.shadow = shadow; |
28
dom.js
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -68,6 +68,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -77,3 +94,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -126,2 +143,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -138,3 +156,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -141,0 +159,0 @@ exports.shadow = shadow; |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object') |
28
index.js
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -256,6 +256,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -265,3 +282,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -1068,2 +1085,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -1080,3 +1098,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -1083,0 +1101,0 @@ exports.shadow = shadow; |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object') |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -256,6 +256,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -265,3 +282,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -1068,2 +1085,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -1080,3 +1098,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -1083,0 +1101,0 @@ exports.shadow = shadow; |
{ | ||
"name": "typed-dom", | ||
"version": "0.0.337", | ||
"version": "0.0.338", | ||
"description": "A value-level and type-level DOM builder.", | ||
@@ -59,7 +59,7 @@ "private": false, | ||
"npm-check-updates": "^16.10.12", | ||
"spica": "0.0.734", | ||
"spica": "0.0.735", | ||
"ts-loader": "^9.4.3", | ||
"typescript": "5.1.3", | ||
"webpack": "^5.85.1", | ||
"webpack-cli": "^5.1.3", | ||
"webpack": "^5.86.0", | ||
"webpack-cli": "^5.1.4", | ||
"webpack-merge": "^5.9.0" | ||
@@ -66,0 +66,0 @@ }, |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -3,0 +3,0 @@ if(typeof exports === 'object' && typeof module === 'object') |
@@ -1,2 +0,2 @@ | ||
/*! typed-dom v0.0.337 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
/*! typed-dom v0.0.338 https://github.com/falsandtru/typed-dom | (c) 2016, falsandtru | (Apache-2.0 AND MPL-2.0) License */ | ||
(function webpackUniversalModuleDefinition(root, factory) { | ||
@@ -68,6 +68,23 @@ if(typeof exports === 'object' && typeof module === 'object') | ||
if (typeof identify === 'object') return memoize(f, undefined, identify); | ||
return (0, alias_1.isArray)(memory) || memory?.constructor === Object ? memoizeRecord(f, identify, memory) : memoizeDict(f, identify, memory ?? new Map()); | ||
switch (true) { | ||
case (0, alias_1.isArray)(memory): | ||
return memoizeArray(f, identify, memory); | ||
case memory?.constructor === Object: | ||
return memoizeObject(f, identify, memory); | ||
default: | ||
return memoizeDict(f, identify, memory ?? new Map()); | ||
} | ||
} | ||
exports.memoize = memoize; | ||
function memoizeRecord(f, identify, memory) { | ||
function memoizeArray(f, identify, memory) { | ||
return (...as) => { | ||
const b = identify(...as); | ||
let z = memory[b]; | ||
if (z !== undefined) return z; | ||
z = f(...as); | ||
memory[b] = z; | ||
return z; | ||
}; | ||
} | ||
function memoizeObject(f, identify, memory) { | ||
let nullable = false; | ||
@@ -77,3 +94,3 @@ return (...as) => { | ||
let z = memory[b]; | ||
if (z !== undefined || nullable && memory[b] !== undefined) return z; | ||
if (z !== undefined || nullable && b in memory) return z; | ||
z = f(...as); | ||
@@ -126,2 +143,3 @@ nullable ||= z === undefined; | ||
(function (caches) { | ||
// Closed only. | ||
caches.shadows = new WeakMap(); | ||
@@ -138,3 +156,3 @@ caches.shadow = (0, memoize_1.memoize)((el, opts) => el.attachShadow(opts), caches.shadows); | ||
mode: 'open' | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadows.get(el) ?? caches.shadow(el, opts), children); | ||
}) : opts.mode === 'open' ? el.shadowRoot ?? el.attachShadow(opts) : caches.shadow(el, opts), children); | ||
} | ||
@@ -141,0 +159,0 @@ exports.shadow = shadow; |
@@ -52,2 +52,3 @@ import { isArray, hasOwnProperty } from 'spica/alias'; | ||
namespace caches { | ||
// Closed only. | ||
export const shadows = new WeakMap<Element, ShadowRoot>(); | ||
@@ -72,3 +73,3 @@ export const shadow = memoize((el: Element, opts: ShadowRootInit) => el.attachShadow(opts), shadows); | ||
? el.shadowRoot ?? el.attachShadow(opts) | ||
: caches.shadows.get(el) ?? caches.shadow(el, opts), | ||
: caches.shadow(el, opts), | ||
children); | ||
@@ -75,0 +76,0 @@ } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
675018
15937