Question: ```
<img src="https://res.cloudinary.com/dvhhqcxre/image/upload/v1611495185/zenith/tldyffcvvfm9fj51pvjp.jpg">

```

I want to get rid of the img tag, I just want only the image link

Answer: 
```js
const image = document.querySelector('img')
image.outerHTML = image.src
```

```html
<img src="https://res.cloudinary.com/dvhhqcxre/image/upload/v1611495185/zenith/tldyffcvvfm9fj51pvjp.jpg">
```
You can use a [`DOMParser`](https://developer.mozilla.org/en-US/docs/Web/API/DOMParser) to parse the string and get the `src` property of the image:

```js
const str = `<img src="https://res.cloudinary.com/dvhhqcxre/image/upload/v1611495185/zenith/tldyffcvvfm9fj51pvjp.jpg">`;

const res = new DOMParser().parseFromString(str, "text/html").querySelector('img').src;
console.log(res)
```