Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
33 lines (27 sloc) 821 Bytes
<template>
<div class="row">
<div class="col-md-8 col-md-offset-2">
<div class="panel panel-default">
<div class="panel-heading">
{{ comment.creator.name }} said
<time :datetime="comment.created_at">
{{ diffForHumans }}
</time>
</div>
<div class="panel-body">
{{ comment.body }}
</div>
</div>
</div>
</div>
</template>
<script>
export default {
props: ['now', 'comment'],
computed: {
diffForHumans: function () {
return moment(this.comment.created_at).from(this.now)
}
}
}
</script>