JSFiddle - React, Tailwind, and code Playground

HTML

<div ng-app ng-controller="MyCtrl">
    <select ng-model="ampm" ng-options="currOption for currOption in ['AM', 'PM']"></select>
    AM/PM: {{ampm}}
</div>

JavaScript

function MyCtrl($scope) {
    $scope.ampm = (new Date().getHours()) >= 12 ? 'PM' : 'AM';
}