1.0.0 • Published 4 years ago

@leahxia/native-ui-components v1.0.0

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

@leahxia/native-ui-components

Getting started

$ npm install @leahxia/native-ui-components --save

Mostly automatic installation

$ react-native link @leahxia/native-ui-components

Manual installation

iOS

  1. In XCode, in the project navigator, right click LibrariesAdd Files to [your project's name]
  2. Go to node_modules@leahxia/native-ui-components and add NativeViewController.xcodeproj
  3. In XCode, in the project navigator, select your project. Add libNativeViewController.a to your project's Build PhasesLink Binary With Libraries
  4. Run your project (Cmd+R)<

Android

  1. Open up android/app/src/main/java/[...]/MainApplication.java
  • Add import com.reactlibrary.NativeViewControllerPackage; to the imports at the top of the file
  • Add new NativeViewControllerPackage() to the list returned by the getPackages() method
  1. Append the following lines to android/settings.gradle:
    include ':@leahxia/native-ui-components'
    project(':@leahxia/native-ui-components').projectDir = new File(rootProject.projectDir, 	'../node_modules/@leahxia/native-ui-components/android')
  2. Insert the following lines inside the dependencies block in android/app/build.gradle:
      compile project(':@leahxia/native-ui-components')

Usage

import NativeViewController from '@leahxia/native-ui-components';

// TODO: What to do with the module?
NativeViewController;