We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f2a77d1 commit 66a98e3Copy full SHA for 66a98e3
libs/angular-three/src/lib/renderer/renderer.ts
@@ -182,6 +182,9 @@ export class NgtRenderer implements Renderer2 {
182
parent.__ngt_renderer__[NgtRendererClassId.type] === 'three' &&
183
newChild.__ngt_renderer__[NgtRendererClassId.type] === 'three'
184
) {
185
+ // if child already attached to a parent, skip
186
+ if (getLocalState(newChild).parent) return;
187
+ // attach THREE child
188
attachThreeChild(parent, newChild);
189
// here, we handle the special case of if the parent has a compoundParent, which means this child is part of a compound parent template
190
if (!newChild.__ngt_renderer__[NgtRendererClassId.compound]) return;
0 commit comments