Reputation: 1114
Have tried loading the template on click of the button but some where approach is wrong templates are not loading.
Here adding the tried plunker:
Can anyone let me know where had gone wrong.
Upvotes: 1
Views: 2744
Reputation: 25892
I think problem is following:
You haven't called the function. you have to say cClick().
You said:-
<button ng-model='template' ng-click='cClick'>Click</button>
try this:-
<button ng-model='template' ng-click='cClick()'>Click</button>
Upvotes: 1