I have a component and it contains a modal.
<div bsModal #lgModal="bs-modal" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<h4 class="modal-title pull-left">Large modal</h4>
<button type="button" class="close pull-right" (click)="lgModal.hide()" aria-label="Close">
<span aria-hidden="true">×</span>
</button>
</div>
<div class="modal-body">
{{current}}
</div>
</div>
</div>
</div>
I open the modal with @ViewChild('lgModal') modal;
and call this.modal.show();
But i want to separate the HTML, So is it possible to call component B
from component A
?