fix(packages): add server-only bundles (#1349)

This commit is contained in:
rahim
2026-04-16 00:59:14 -07:00
committed by GitHub
parent 4ecc870685
commit 3331fdaf25
60 changed files with 654 additions and 215 deletions
+6 -1
View File
@@ -50,7 +50,12 @@ const propertyKeys = new Map<string, symbol>();
* }
* ```
*/
export class ReactiveElement extends HTMLElement {
// Fallback to an empty class when `HTMLElement` is not available (SSR / Node).
// This allows the class definition to evaluate without throwing; instances
// are never created on the server.
const BaseElement = globalThis.HTMLElement ?? (class {} as unknown as typeof HTMLElement);
export class ReactiveElement extends BaseElement {
/**
* User-supplied object that maps property names to
* {@linkcode PropertyDeclaration} objects containing options for configuring