New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

react-native-image-size-android

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-image-size-android

Provides accurate width and height for Android content:// image URIs using MediaStore. A simple React Native native module.

latest
Source
npmnpm
Version
0.1.3
Version published
Maintainers
1
Created
Source

📸 react-native-image-size-android

A simple React Native native module for retrieving accurate image dimensions (width & height) from content:// URIs on Android devices using the MediaStore API.

✅ Android only
❌ Not compatible with iOS

🚀 Features

  • 🔍 Retrieve image size from Android MediaStore
  • ⚡ Works with content:// URIs (e.g. selected images from gallery)
  • 📦 Lightweight and easy to use
  • 🔧 Written in Kotlin + TypeScript
  • 💬 Fully typed API

📦 Installation

Using npm:

npm install react-native-image-size-android
yarn add react-native-image-size-android

Usage

import { getImageSize } from 'react-native-image-size-android';

type ImageSize = {
  width: number;
  height: number;
};

const uri = 'content://media/external/images/media/123';

try {
  const size = await getImageSize(uri);
  console.log('Image size:', size.width, size.height);
} catch (error) {
  console.error('Failed to get image size:', error);
}

License

MIT © Görkem Başaran

Made with create-react-native-library

Keywords

react-native

FAQs

Package last updated on 18 Jul 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts