Display corps birthday
- Lenguaje dominante
- TypeScript
- Estrellas
- 5
- Forks
- 1
- Merge medio
- 15 min
- PR fusionados (30 d)
- 21
Descripción
Add a cake emoji (🎂) at the end of a corps' name in CorpsDisplay if the current date is their corps-birthday. Meaning, the date of their first rehearsal or first gig (whichever is earliest).
This date is already calculated when building the text in the component (in "Gick med i corpset..."), so preferably this value should be reused in both places. Even MORE preferably the calculation should be moved out to its own function in the corps/stats router.
To keep the router function pure either the component or router API could take `currentDate` as an argument and use that for checking if the current date is their corps-birthday, rather than using `new Date()` directly in the code, as that would make the function non-pure.
Guía de contribución
Línea de trabajo
Inspecciona CorpsDisplay y el router corps/stats, empezando por el cálculo de fecha existente que se usa para el texto “Gick med i corpset...”. Reutiliza o extrae ese cálculo y ten en cuenta currentDate para que la lógica siga siendo pura. La tarea estará terminada cuando aparezca un 🎂 después del nombre del corps únicamente en el cumpleaños del corps, basándose en la fecha más antigua de un primer ensayo o de un primer concierto.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- typescript
- Área
- full-stack
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 55/100