Updated weather cards
This commit is contained in:
@@ -104,8 +104,9 @@ export default function Homepage({ theme }: any) {
|
||||
precipitation:
|
||||
weather.features[0].properties.precipitationLastHour.value || 'N/A',
|
||||
humidity: Math.round(weather.features[0].properties.relativeHumidity.value),
|
||||
heatIndex: Math.round(
|
||||
(weather.features[0].properties.heatIndex.value * 9) / 5 + 32,
|
||||
heatIndex: Math.round(weather.features[0].properties.heatIndex.value !== null ?
|
||||
(weather.features[0].properties.heatIndex.value * 9) / 5 + 32
|
||||
: (weather.features[0].properties.temperature.value * 9) / 5 + 32,
|
||||
),
|
||||
windSpeed: Math.round(weather.features[0].properties.windSpeed.value / 1.60934),
|
||||
windDirection: weather.features[0].properties.windDirection.value,
|
||||
|
||||
Reference in New Issue
Block a user