JSFiddle - React, Tailwind, and code Playground

by bigbiff02

HTML

<div ng-app="app">
    <div ng-controller="ctrl">
        <table>
            <tr ng-repeat="theCustomer in customers">
                <td>
                    <input type="radio" ng-model="$parent.currentCustomer" name="foo" value="{{theCustomer}}" id="{{theCustomer.id}}">{{theCustomer.name}}</td>
            </tr>
        </table>
        <br>
        <div>{{currentCustomer}}</div>
    </div>
</div>

JavaScript

var app = angular.module("app", []);

app.controller("ctrl", function ($scope) {
    $scope.customers = [{
        "id": 1,
        "name": "Bill"
    }, {
        "id": 2,
        "name": "Bob"
    }, {
        "id": 3,
        "name": "Biff"
    }];
    $scope.customer = {};
    $scope.currentCustomer = {};

})