Ng-init is used to initialization. In this example of ng-init, test variable is bound with textbox and it is initialized with value "LearnKode" using ng-init directive as ng-init="test='LearnKode'"
. So wherever the variable is being used, will be set to "LearnKode" . See the code snippet: