I have created a view (A HTML file consisting of some divs and input boxes) and now I want to use that file as a view at different places but with different data models binded to it. "I mean change in ng-model of input tags"
One way is to make same view again and again and bind it with respective data model. But I don't want it.. How can I use only one HTML file as a view and bind it with different model at different place?
P.S : I am somewhat new to Angular-JS
Do you mean useing different controllers with the same html template? If your using
ngRoute
you could set it up like thisHere is a tutorial on setting up routing: https://docs.angularjs.org/tutorial/step_07