0.2.0 • Published 7 years ago

img-exif v0.2.0

Weekly downloads
1
License
MIT
Repository
github
Last release
7 years ago

<img-exif>

This vanilla web component simply takes a src attribute like the standard img element and renders it in it's correct orientation using any embedded EXIF data.

Note: This component only works for same-origin images or images with cross-origin headers!

img-exif has no dependencies (but may require a polyfill).

Install

Install img-exif with your preferred node package manager.

$ yarn add img-exif

or

$ npm install --save img-exif

You will need to include any polyfills for browsers that do not support the Web Components v1 spec. See https://github.com/webcomponents/webcomponentsjs.

Usage

Import the HTML file in the <head> after installing.

<link rel="import" href="./node_modules/img-exif/img-exif.html">

Use the tag on your page.

<img-exif src="./your-image.jpg"></img-exif>

Options

AttributeTypeDefaultDescription
srcurlSame as <img src="">

Limitations

  • No option to use height= or width= attributes. Use CSS width: and height: properties instead.

History

For changelog, see releases.

License

MIT License

0.2.0

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago