JSFiddle - React, Tailwind, and code Playground

by mkbharti

HTML

<div ng-app='MyModule' ng-controller="MyController">
    <table border="1">
        <thead>
            <tr>
                <th><input type="text" ng-model="search.id"/></th>
                <th><input type="text" ng-model="search.name"/></th>
                <th><input type="text" ng-model="search.shade"/></th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <tr ng-repeat="c in colors | filter:search">
                    <td>{{c.id}}</td>
                    <td>{{c.name}}</td>
                    <td>{{c.shade}}</td>
                </tr>
            </tr>
        </tbody>
    </table>
</div>

JavaScript

angular.module('MyModule', [])

.controller('MyController', function( $scope ) {
    
    $scope.colors = [
        {id: 11, name: 'black', shade: 'dark'},
        {id: 22, name: 'white', shade: 'light'},
        {id: 32, name: 'red', shade: 'dark'},
        {id: 44, name: 'blue', shade: 'dark'},
        {id: 5, name: 'yellow', shade: 'light'}
    ];
});