I have a Razor for loop:
@foreach (var user in Model.Users)
{
<p class="active-text">Active: @user.LastActive</p>
}
I've just installed moment.js to format this DateTime() date using js.
How can I pass the Razor model into a javascript function? I do have a JS viewmodel for this page, I'm just trying to avoid serializing the entire Model just because I need to apply some JS to a single field. How my viewModel stands right now:
<script type="text/javascript">
$(document).ready(ko.applyBindings(new SubjectVm()));
</script>