text: import React, {useState, useEffect} from 'react';
  import './App.css';
  
  
  function App() {
    const [lat, setLat] = useState([]);
    const [long, setLong] = useState([]);
    const [data, setData] = useState([])
  
    useEffect(() => {
      const fetchData = async () => {
      navigator.geolocation.getCurrentPosition(function(position) {
        setLat(position.coords.latitude)
        setLong(position.coords.longitude)
      })
  
      await fetch(`${process.env.REACT_APP_API_URL}/weather/?lat=${lat}&lon=${long}&units=metric&APPID=${process.env.REACT_APP_API_KEY}`)
        .then(res => res.json())
        .then(result => {
          setData(result)
          console.log(result);
        })
      }
      console.log('Latitude is: ', lat )
      console.log('Longitute is: ', long )
      fetchData()
    }, [lat, long])
  
  
    return (
      <div className="App">
        <h1>Weather Application</h1>
      </div>
    );
  }
  
  export default App;
  