JSFiddle - React, Tailwind, and code Playground
by scyrizales
HTML
<div ng-app="myApp" ng-controller="Ctrl1">
<button ng-click="mostrar()">Cambiar</button>
{{ visible }}
<br/>
<div ng-show="visible == true">
<input type="text" ng-model="mundo" />
<br/>
Hola {{mundo}}
<button ng-click="mundo = 'algo'">Click Me</button>
<span class="{{mundo}}">ejemplo</span>
</div>
<hr/>
Filtro: <input type="text" ng-model="filtro"/>
<div ng-repeat="item in items | filter:filtro">
{{ item.nombre }}
</div>
<hr/>
Formato: <input type="text" ng-model="formato" />
<div>{{ now | date:formato }}</div>
</div>
CSS
.algo {
color: red;
}
JavaScript
angular.module("myApp", [])
.controller("Ctrl1", ["$scope", function ($scope){
$scope.mundo = "Sergio";
$scope.visible = true;
$scope.mostrar = function(){
$scope.visible = !a.visible;
}
$scope.items = [
{nombre:"ab"},
{nombre:"bc"},
{nombre:"cd"}
];
$scope.now = new Date();
}]);