File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed
libs/core/src/lib/renderer Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -68,7 +68,19 @@ export function attachThreeChild(parent: NgtInstanceNode, child: NgtInstanceNode
6868 const attachProp = cLS . attach ;
6969
7070 if ( typeof attachProp === 'function' ) {
71- const attachCleanUp = attachProp ( parent , child , cLS . store ) ;
71+ let attachCleanUp : ReturnType < typeof attachProp > | undefined = undefined ;
72+
73+ if ( cLS . isRaw ) {
74+ if ( cLS . instanceStore . get ( 'parent' ) !== parent ) {
75+ cLS . setParent ( parent ) ;
76+ }
77+ // at this point we don't have rawValue yet, so we bail and wait until the Renderer recalls attach
78+ if ( child . __ngt_renderer__ [ NgtRendererClassId . rawValue ] === undefined ) return ;
79+ attachCleanUp = attachProp ( parent , child . __ngt_renderer__ [ NgtRendererClassId . rawValue ] , cLS . store ) ;
80+ } else {
81+ attachCleanUp = attachProp ( parent , child , cLS . store ) ;
82+ }
83+
7284 if ( attachCleanUp ) cLS . previousAttach = attachCleanUp ;
7385 } else {
7486 // we skip attach none if set explicitly
You can’t perform that action at this time.
0 commit comments