Set result to the result of constructing C, with no
arguments.
-
Assert: result's custom element state and
- custom element definition are initialized.
+
+ Assert: one of the following is true:
+
+
+ - result's custom element state is "
custom"
+ and its custom element definition is non-null;
+ - result's custom element state is
+ "
precustomized"; or
+ - result's custom element state is neither
+ "
custom" nor "precustomized" and its
+ custom element definition is null.
+
+
+
+
+ customElements.define("x-example", class extends HTMLElement {
+ constructor() {
+ // Non-conformant: returns an existing element instead of calling super().
+ return document.createElement("p");
+ }
+ });
+
+ document.createElement("x-example");
+
+
+ Here result is the p element, whose
+ custom element state is "uncustomized" and whose
+ custom element definition is null.
+
Assert: result's namespace is the HTML namespace.