Trying to conditionally render values from an array object if isDayTime is equal to true.
Tried .filter and .map but I don't think I'm doing it properly.
const weather = this.props.weather.weatherData;
return weather.map(weather => {
if (weather.isDayTime === true) {
return (
<div className="ui segment">
<div className="ui center grey aligned header">TheDay</div>
<div className="ui center grey aligned header">
<i className="sun icon" />
</div>
<div className="ui center grey aligned sub header">
Min:75° Max:80°
</div>
</div>
);
}
});
}
}