const url='https://api.mapbox.com/geocoding/v5/mapbox.places/Los%20Angeles.json?access_token=pk.eyJ1Ijoic2FtLWhhd2t6IiwiYSI6ImNrMDl2YXU4aTBieTEzY252aHpvZHd5Y3YifQ.v8Xh5bZiNbkTR7FlQwIgYQ' request=({url:url, json:true}, (error,response) =>{
const latitude = response.body.features[0].center[0]
const longitude = response.body.features[0].center[1]
console.log(latitude,longitude) })
Here I used an api to geocode my location but I'm getting a TypeError: Assigment to const variable. According to me that error should only come when the const value is changing in the code but it's staying the same throughout then where is the problem?
=in the first line after url