mirror of
https://github.com/hazemKrimi/react-weather-app.git
synced 2026-05-02 02:30:30 +00:00
Update home page
This commit is contained in:
@@ -100,8 +100,6 @@ const Home: React.FC = () => {
|
|||||||
const [ forecast, setForecast ] = useState<Forecast | null>(null);
|
const [ forecast, setForecast ] = useState<Forecast | null>(null);
|
||||||
const [ loading, setLoading ] = useState<boolean>(true);
|
const [ loading, setLoading ] = useState<boolean>(true);
|
||||||
const [ error, setError ] = useState<string>('');
|
const [ error, setError ] = useState<string>('');
|
||||||
const [ dailyForecastPosition, setDailyForecastPosition ] = useState<number>(0);
|
|
||||||
const [ hourlyForecastPosition, setHourlyForecastPosition ] = useState<number>(0);
|
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!navigator.geolocation) setError('Geolocation not supported in this browser! Try searching for a city instead');
|
if (!navigator.geolocation) setError('Geolocation not supported in this browser! Try searching for a city instead');
|
||||||
|
|||||||
Reference in New Issue
Block a user