Get exact device density and ppi for React Native.
React Native build-in PixelRatio can get device density using PixelRatio.get(), but the return value has been rounded. This package will return the exact value of device density
npm install --save react-native-exact-ratio
import { DeviceRatio } from 'react-native-exact-ratio'
console.log('Device Density:', DeviceRatio.density)
console.log('Device DPI:', DeviceRatio.dpi)
cd example
npm install && cd ios && pod install && cd ..
react-native run-ios