Skip to content

Commit

Permalink
fix: code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
joshhowenstine committed Nov 19, 2024
1 parent 5b016e7 commit d60cfd2
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -623,8 +623,9 @@ export function generateNameFromPrototypeChain(obj, name = '') {
if (!obj) return name;
const proto = Object.getPrototypeOf(obj);
if (!proto || !proto.constructor) return name;
const componentName = `${name ? name + '.' : ''}${proto?.constructor?.__componentName || ''
}`
const componentName = `${name ? name + '.' : ''}${
proto?.constructor?.__componentName || ''
}`
.replace(/\.*$/, '')
.trim();
const result = generateNameFromPrototypeChain(proto, componentName);
Expand Down

0 comments on commit d60cfd2

Please sign in to comment.