MCPcopy Create free account
hub / github.com/UI5/webcomponents / preprocess

Function preprocess

packages/base/src/jsx-utils.ts:38–53  ·  view source on GitHub ↗
(type: string | typeof UI5Element, props: Record<string, any>, key: string)

Source from the content-addressed store, hash-verified

36}
37
38export function preprocess(type: string | typeof UI5Element, props: Record<string, any>, key: string) {
39 let tag: string;
40 if (isUI5ElementClass(type)) {
41 tag = type.getMetadata().getTag();
42 convertEventScoping(type, props, key);
43 } else {
44 tag = type;
45 }
46
47 // convert class object to string
48 if (typeof props.class === "object") {
49 props.class = hash2str(props.class);
50 }
51
52 return tag;
53}

Callers 3

jsxDEVFunction · 0.90
jsxFunction · 0.90
jsxsFunction · 0.90

Calls 5

isUI5ElementClassFunction · 0.85
convertEventScopingFunction · 0.85
hash2strFunction · 0.85
getTagMethod · 0.80
getMetadataMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…