- creator<K>(name): ((this) => ElementTagNameMap[K])
Type Parameters
K extends "symbol" | "filter" | "g" | "animate" | "animateMotion" | "animateTransform" | "circle" | "clipPath" | "defs" | "desc" | "ellipse" | "feBlend" | "feColorMatrix" | "feComponentTransfer" | "feComposite" | "feConvolveMatrix" | "feDiffuseLighting" | "feDisplacementMap" | "feDistantLight" | "feDropShadow" | "feFlood" | "feFuncA" | "feFuncB" | "feFuncG" | "feFuncR" | "feGaussianBlur" | "feImage" | "feMerge" | "feMergeNode" | "feMorphology" | "feOffset" | "fePointLight" | "feSpecularLighting" | "feSpotLight" | "feTile" | "feTurbulence" | "foreignObject" | "image" | "line" | "linearGradient" | "marker" | "mask" | "metadata" | "mpath" | "path" | "pattern" | "polygon" | "polyline" | "radialGradient" | "rect" | "set" | "stop" | "svg" | "switch" | "text" | "textPath" | "tspan" | "use" | "view" | keyof HTMLElementTagNameMap
Returns ((this) => ElementTagNameMap[K])
- (this): ElementTagNameMap[K]
Returns ElementTagNameMap[K]
- creator<NewGElement>(name): ((this) => NewGElement)
Returns ((this) => NewGElement)
- (this): NewGElement
Returns NewGElement
Given the specified element name, returns a function which creates an element of the given name, assuming that "this" is the parent element.