khayym / react-native-pictures

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

React-Native-Pictures

demo.mp4

React Native Pictures is a comprehensive toolkit for handling images within your React Native application. Our goal is to provide a modern, efficient codebase using Swift and Kotlin, offering common solutions for image-related features in your React Native app.

This library integrates a custom native iOS implementation and utilizes PhotoView on Android. Please note that this project is in its early stages—expect breaking changes before the release of v1.

Installation

npm install react-native-pictures

Usage

Here's a simple example to showcase how you can use React Native Pictures in your app:

import PictureManager from 'react-native-pictures';

// ...

const imageUrl = "https://images.unsplash.com/photo-1462331940025-496dfbfc7564"
const result = PictureManager.openPictureViewer(imageUrl);

API

For now, the only function supported is openPictureViewer(url: string). More to come!

Roadmap

  • Custom Android Implementation: Replace PhotoView with a custom implementation, as PhotoView is no longer maintained.
  • Native Component Integration: Transition from Activity/UIViewController to View/UIView for seamless embedding within React Native screens. This will allow greater flexibility for consumer applications.
  • Image Cropping Feature: Implement a cropping feature to leverage the pan and zoom capabilities, making it easier to integrate an image cropping screen.

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT


Made with create-react-native-library

About

License:MIT License


Languages

Language:Swift 30.9%Language:Kotlin 25.3%Language:Ruby 14.6%Language:Objective-C 9.4%Language:JavaScript 8.4%Language:TypeScript 6.5%Language:Objective-C++ 4.5%Language:C 0.4%