DEV Community

Discussion on: Clean your condition ๐Ÿงผ

Collapse
jiko profile image
Jiko
const getStatus = (status = 'loading') => statusColors?.[status] ?? statusColors.loading;
Enter fullscreen mode Exit fullscreen mode