i have the following code: and the data binding is not working when using ionic. if you copy and paste this code in plunker you will see that on every key entry it will clear the input. This is not the case when using ionic. Has anyone had a similar issue?
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Example - example-ngChange-directive-production</title>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.3.0-beta.2/angular.min.js"></script>
</head>
<body ng-app="">
<script>
function Controller($scope) {
tester = ["d", "d", "dfsd"];
$scope.me = "me";
$scope.testing = tester;
$scope.counter = 0;
$scope.change = function() {
$scope.counter++;
tester.push($scope.confirmed.stuff);
$scope.confirmed = '';
};
}
</script>
<div ng-controller="Controller">
<input type="text" ng-model="confirmed.stuff" ng-change="change()" id="ng-change-example1" />
<label for="ng-change-example2">Confirmed</label>
<br />
<tt>debug = {{confirmed}}</tt>
<br/>
<tt>counter = {{counter}}</tt>
<br/>
<div ng-repeat="test in testing track by $index">{{test}}</div>
</div>
</body>
</html>