1fetch("https://rickandmorty.mimo.dev/api/location/9") 2 .then((res) => res.json())3 .then((json) => console.log(json))4 .catch((error) => console.error(error))
1{2 "id": 9,3 "name": "Purge Planet",4 "type": "Planet",5 "dimension": "Replacement Dimension",6 "residents": [7 "https://rickandmorty.mimo.dev/api/character/26",8 "https://rickandmorty.mimo.dev/api/character/139",9 "https://rickandmorty.mimo.dev/api/character/202",10 "https://rickandmorty.mimo.dev/api/character/273"11 ],12 "url": "https://rickandmorty.mimo.dev/api/location/9",13 "created": "2017-11-10T13:09:29.566Z"14}