local-weather/components/Temperature.tsx
ChrQR a21c44185f added weather to context provided by weatherNow.
The application structure and naming should take in to account the weathernow component will be the container
2024-05-10 01:10:37 +02:00

15 lines
319 B
TypeScript

import { TempInfo } from "@/types/types";
import { useContext } from "react";
import { WeatherContext } from "./WeatherNow";
export default function Temperature() {
const { weather } = useContext(WeatherContext)
const feels = weather.current.apparent_temperature;
return (
<p>{feels}°C</p>
)
}