I find myself with the difficulty that I cannot format the date in react, the following code was written in VUE JS and it ran perfectly. I would like someone to help me understand this concept please. The code is the following :
import spanish from 'date-fns/locale/es';
import parseISO from 'date-fns/parseISO'
import axios from 'axios';
<ListItem
style={styles.list}
title={<Text>{info.item.name}</Text>}
description={<Text style={styles.list}>{`${info.item.description}`}</Text>}
date={<Text>{format((parseISO(info.item.date)), 'dd/MMMM/yy', {locale: spanish})}
</Text>}
accessoryLeft={renderItemIcon}
onPress={() => navigation.push('Validator', {data: info.item, email: email})}
>
</ListItem>