Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question]: can we dynamically update the template? #138

Closed
tmtron opened this issue Jul 29, 2020 · 2 comments
Closed

[Question]: can we dynamically update the template? #138

tmtron opened this issue Jul 29, 2020 · 2 comments

Comments

@tmtron
Copy link

tmtron commented Jul 29, 2020

In our use-case we have 2 very different templates for blocking the UI:

  1. during loading - we just show a loading spinner
  2. when an error has occurred: we show a reload icon + message and the user can click on the template to retry

The current issue, is that we found no way to change the template once it has been assigned.
Did we miss something?

Our workaround for now is to have only on component and pass some config parameters as explained in #95

@kuuurt13
Copy link
Owner

@tmtron this currently isn't possible because the template is only set on ngAfterViewInit. With that being said I think it should be possible to also update during ngOnChanges. Let me take a look and see if I can make this change.

@tmtron
Copy link
Author

tmtron commented Jul 29, 2020

Okay - never mind. I think I can live with one template and config parameters. Feel free to close this.

If you really want to add this feature it may be convenient to pass the template component in the start() function

@kuuurt13 kuuurt13 closed this as completed Sep 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants