img-alter
Microsoft Vision API.
A Javascript module to fill 'ALT' attribute of all images in a web page usingInstallation and Usage
here.
1)Get free Microsoft Vision API Key fromMicrosoft Vision uses deep learning to analyse an image.
npm
or bower
2)Install via With npm :
npm install img-alter --save
With bower :
bower install img-alter --save
img-alter.js
or img-alter.min.js
to html file.
3) Add <script src="bower_components/img-alter/img-alter.js" type="text/javascript"></script>
4) Invoke API
Once the page load completes, Invoke
ImageAlter.fillImageAltTags({apiKey:"xxxxxxxxxxxxx"})
This will replace alternative attribute of all images in a webpage with its caption. Replace xxxxxxxxxxxxx
with your own API Key.
Sample Images with Captions
Bill Clinton in a suit and tie
a laptop computer
a fireworks in the dark
a close up of a pizza on a wooden table
a fighter jet flying in the sky
a woman talking on a cell phone