()
| 428 | * @codeGenApi |
| 429 | */ |
| 430 | export function ɵɵdeferOnImmediate() { |
| 431 | const lView = getLView(); |
| 432 | const tNode = getCurrentTNode()!; |
| 433 | |
| 434 | if (ngDevMode) { |
| 435 | trackTriggerForDebugging(lView[TVIEW], tNode, 'on immediate'); |
| 436 | } |
| 437 | |
| 438 | if (!shouldAttachTrigger(TriggerType.Regular, lView, tNode)) return; |
| 439 | |
| 440 | // Render placeholder block only if loading template is not present and we're on |
| 441 | // the client to avoid content flickering, since it would be immediately replaced |
| 442 | // by the loading block. |
| 443 | const tDetails = getTDeferBlockDetails(lView[TVIEW], tNode); |
| 444 | if (tDetails.loadingTmplIndex === null) { |
| 445 | renderPlaceholder(lView, tNode); |
| 446 | } |
| 447 | triggerDeferBlock(TriggerType.Regular, lView, tNode); |
| 448 | } |
| 449 | |
| 450 | /** |
| 451 | * Sets up logic to handle the `prefetch on immediate` deferred trigger. |
nothing calls this directly
no test coverage detected