@pedro.gabriel/react-native-exif
v1.0.2
Published
React Native Exif
Maintainers
Readme
React Native Exif
Installation
yarn add @pedro.gabriel/react-native-exif
react-native linkor
npm install @pedro.gabriel/react-native-exif --save
react-native linkUsage
getExif
import { getExif, getLatLong } from '@pedro.gabriel/react-native-exif'
...
getExif('/sdcard/tt.jpg')
.then(msg => console.warn('OK: ' + JSON.stringify(msg)))
.catch(msg => console.warn('ERROR: ' + msg))
...
getExif('content://media/external/images/media/111')
.then(msg => console.warn('OK: ' + JSON.stringify(msg)))
.catch(msg => console.warn('ERROR: ' + msg))
...
getExif('assets-library://asset/asset.JPG?id=xxxx&ext=JPG')
.then(msg => console.warn('OK: ' + JSON.stringify(msg)))
.catch(msg => console.warn('ERROR: ' + msg))
Exif values
| Value | | ----------- | | ImageWidth | | ImageHeight | | Orientation | | originalUri | | exif |
getLatLong
Fetch geo coordinates as floats.
...
getLatLong('/sdcard/tt.jpg')
.then(({latitude, longitude}) => {console.warn('OK: ' + latitude + ', ' + longitude)})
.catch(msg => console.warn('ERROR: ' + msg))
...Version 1.0.0 add react-native 0.81.1 support
