Time Format in table conditional formatting

I want to show time in table only when it is not '0:00' in H:mm format.
I Get date like this: 2024-01-08T00:00:00.000Z

{{ moment(item).format('H:mm') === '0:00' ? '' : 'H:mm'}}

This is the error I get:
Must be a valid unicode datetime format.

Welcome to the forum!
What is the time format being displayed before you are testing the logic?

I have set it to H:mm

image
image

You could try using item.includes('0:00')?'':moment(item).format('H:mm')
but you could also try to remove the month date and year first and then use the move

image
I want just as I would write only H:mm in time format. for some reason I always get Error if I do this

I think the problem is that your item contains all of the information and you're trying to parse just the time so you may need to transform the data before it gets displayed in the table.... try adjusting the query to only get the time and not the date month and year.