<p> {Math.max(0, foo)} {bar} </p> <script> export default { computed: { bar: ({ foo }) => foo * 2 } }; </script>