Ng-model does not update controller value
问题 Probably silly question, but I have my html form with simple input and button: <input type=\"text\" ng-model=\"searchText\" /> <button ng-click=\"check()\">Check!</button> {{ searchText }} Then in the controller (template and controller are called from routeProvider): $scope.check = function () { console.log($scope.searchText); } Why do I see the view updated correctly but undefined in the console when clicking the button? Thanks! Update: Seems like I have actually solved that issue (before