export const sliceDate = (date: string) => {
  return `${date.slice(8, 10)}.${date.slice(5, 7)}.${date.slice(
    0,
    4
  )}`;
};

export const sliceLocation = (location: string) => {
  if (location.length > 15) return `${location.slice(0, 15)}...`;

  return location;
};

export const sliceDescription = (description: string) => {
  if (description.length > 49) {
    return `${description.slice(0, 50)}...`;
  }

  return description;
};
