Get the 'src' value from any string containing a src="" (embed, iframe, html, etc).
npm install get-src> Get the 'src' value from any string containing a src="" (embed, iframe, html, etc).
```
$ npm install --save get-src
`js
const getSrc = require('get-src');
getSrc('
//=> 'image.png'
getSrc('');
//=> 'video.mp4'
`
#### input
Type: string
The string containing the src="" from which you want to extract the src value.
Currently, there is only support for double quotes, meaning the value you want to extract must
rest inside two double quotes:
Valid
`js`
src="this is valid"
Invalid
`js``
src='this will return undefined'
Pull requests are welcome if you want to add support for double AND single quotes.
MIT © Michael Wuergler