Skip to content
 
 

Repository files navigation

Cloudinary React Native SDK

Build Status

About

The Cloudinary React Native SDK allows you to quickly and easily integrate your application with Cloudinary. Effortlessly optimize and transform your cloud's assets.

Note

This Readme provides basic installation and usage information.

Table of Contents

Key Features

Transform and optimize assets. Visit our documentation to learn more about media optimization and transformations.

Version Support

SDK Version React Native Version
0.0.1 > 0.6

Installation

Install using your favorite package manager (yarn, npm)

npm install cloudinary-react-native

Or

yarn add cloudinary-react-native --save

Usage

Setup

The Cloudinary class is the main entry point for using the library. Your cloud_name is required to create an instance of this class. Your api_key and api_secret are also needed to perform secure API calls to Cloudinary (e.g., image and video uploads). Setting the configuration parameters can be done either programmatically using an appropriate constructor of the Cloudinary class or globally using an environment variable. You can find your account-specific configuration parameters in the Dashboard page of your account console.

Here's an example of setting configuration parameters in your React Native application:

import { AdvancedImage } from 'cloudinary-react-native';
import { Cloudinary } from '@cloudinary/url-gen';

Transform and Optimize Assets

import { AdvancedImage } from 'cloudinary-react-native';
import {Cloudinary} from '@cloudinary/url-gen';

const myCld = new Cloudinary({
  cloud: {
    cloudName: "demo",
  },
});

let img = myCld.image('sample');

export default function App() {
  return (
    <View style={styles.container}>
      <AdvancedImage cldImg={createMyImage()} style={{width:300, height:200}}/>
    </View>
  );
};

Contributions

See contributing guidelines.

Get Help

If you run into an issue or have a question, you can either:

About Cloudinary

Cloudinary is a powerful media API for websites and mobile apps alike, Cloudinary enables developers to efficiently manage, transform, optimize, and deliver images and videos through multiple CDNs. Ultimately, viewers enjoy responsive and personalized visual-media experiences—irrespective of the viewing device.

Additional Resources

Licence

Released under the MIT license.

About

⚡️ High-performance image delivery and uploading at scale in React Native powered by Cloudinary.

Topics

Resources

Contributing

Stars

27 stars

Watchers

15 watching

Forks

Releases

Packages

Used by

Contributors

Languages