# react-native-demo **Repository Path**: justlearn/react-native-demo ## Basic Information - **Project Name**: react-native-demo - **Description**: App项目实例 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2017-09-14 - **Last Updated**: 2020-12-19 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # antd-mobile react-native demo ### use antd-mobile in react-native project 1. install dep ```bash $ npm install antd-mobile --save $ npm install babel-plugin-import --save-dev ``` 2. config `.babelrc` ```json {"plugins": [["import", { "libraryName": "antd-mobile" }]]} ``` ### sample code ```jsx import React, { Component } from 'react'; import { AppRegistry } from 'react-native'; import { Button } from 'antd-mobile'; class HelloWorldApp extends Component { render() { return ; } } AppRegistry.registerComponent('HelloWorldApp', () => HelloWorldApp); ```