Coder Social home page Coder Social logo

jacobp100 / react-native-set-app-icon Goto Github PK

View Code? Open in Web Editor NEW

This project forked from appandflow/react-native-set-app-icon

0.0 2.0 0.0 643 KB

Set the app icon in your react-native in app

Java 29.73% JavaScript 2.06% Objective-C 51.62% Ruby 16.59%

react-native-set-app-icon's Introduction

react-native-set-app-icon

Let your users dynamically change their app icons directly from within the app.

ANDROID IN PROGRESS

Getting started

$ npm install react-native-set-app-icon --save

Mostly automatic installation

$ react-native link react-native-set-app-icon

IOS

Setup XCode

Put all your images as @2x.png @3x.png in the root of your project setup.

Once that's done, go to Info.plist and follow this setup :

Usage

import SetAppIcon from "react-native-set-app-icon";

changeAppIcon

Promise that returns a boolean. Takes the iconName name set in your config.

SetAppIcon.changeIcon(iconName: string): Promise<boolean>;

If you want to set the default back just use null.

SetAppIcon.changeIcon(null);

getIconName

Takes a callback and receives an object with iconName in it.

SetAppIcon.getIconName(cb: (icon: { iconName: string }) => void): void;

supportsDynamicAppIcon

Returns a Promise with a boolean if the device accepts the dynamic app icon change.

SetAppIcon.supportsDynamicAppIcon(): Promise<boolean>;

react-native-set-app-icon's People

Contributors

equimper avatar jacobp100 avatar matmartic avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.