-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🐛 Fix outcomes,diagnosis,phenotype ages #3819
Conversation
✅ Deploy Preview for portal-qa-next-kidsfirstdrc ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for portal-pre-prod-kidsfirstdrc ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Coverage report
Test suite run success0 tests passing in 0 suite. Report generated by 🧪jest coverage report action from e3d9f4f |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Déplacé pour une visibilité plus grande à travers le projet
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Déplacé pour une visibilité plus grande à travers le projet
@@ -35,3 +35,5 @@ export const toKebabCase = (str: string) => { | |||
const match: string[] = (str && str.match(KEBAB_REGEX)) || []; | |||
return match.map((x: string) => x.toLowerCase()).join('-'); | |||
}; | |||
|
|||
export const isNumber = (n: unknown): boolean => typeof n === 'number'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pourquoi cette methode ? on ne peut pas utiliser isNaN()
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Je pense que typeof est plus safe dans le cas qui nous intéresse, j'ai tenté avec isNaN et j'ai eu des bizzareries
.filter((x) => isNumber(x)); | ||
return outcomeAges.length > 0 | ||
? outcomeAges.map((age: number, index: number) => ( | ||
<AgeCell key={`${index}-${age}`} ageInDays={age} /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comme dans AgeCell c'est un fragment, s'il y a plusieurs ages je ne suis pas sur que ça ira à la ligne ... il n'y aura pas d'espace entre les valeurs non ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bon point, je n'avais qu un seul élément à tester. je recorrigerai si besoin avec un exemple précis.
No description provided.