The following JS libraries are supported in the Appsmith platform.
The utility functions provided by the included libraries can be used when transforming data.
An example of lodash's _.map
utility, in use.
{{_.map(fetchFruits.data, (fruit) => {return { label: fruit.name, value: fruit.id }})}}​// fetchFruits is the name of the API / Query
An example of moment's format
utility, in use in a Table's data property.
{{_.map(getTickets.data, (ticket) => ({label: ticket.name,description: ticket.desc,displayDate: moment(ticket.created_date).format("L") // user friendly display date}))}}​// getTickets is the name of the API / Query