<template>
   <span v-if="isCounterAvailable"
         class="badge rounded-pill bg-danger">
      {{ count }}
   </span>
</template>

<script>
export default {
   name: "TabCounter",
   props: ['count'],
   computed: {
      isCounterAvailable() {
         return (typeof this.count !== 'undefined' && this.count > 0 )
      }
   }
}
</script>