0
<div class="flex-container-new">

    <div class="header-alert-gauges">
        <div style="margin: 0px 2px 0px 26px;">
            <dashboard-header></dashboard-header>
        </div>
        <div class="alret-container" style="margin:25px 5px 2px 26px;">
             **<dashboard-body></dashboard-body>**
        </div>

    </div>
    <div class="dashboard-aside-MFN">
        <dashboard-aside class="dashboard-aside-flex-container"></dashboard-aside>
        </div>
    </div>

How can I make dashboard-body lazy load, can some some share the sample code or any link available where I can refer.

1 Answer 1

1

I think you can refer to the following post.

https://medium.com/angular-in-depth/lazy-load-components-in-angular-596357ab05d8

But it's a little bit complicated. So you can rather use ngIf and implement a conditional rendering with some boolean variable.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.