Description
This is the demo project for RNOH Autolinking.
Directory Structure
AutolinkingSample
├── NativeProject harmony工程
├── react-native-oh RNOH前端及手脚架
├── ReactProject 前端工程
├── screenshots 效果图
├── third-party-library-sample RN三方件示例
└── README.md
Environment Setup
- Save
react-native-oh-react-native-harmony-0.84.xx.tgzandreact-native-oh-react-native-harmony-cli-0.84.xx.tgzto thereact-native-ohfolder. - Run npm pack in
third-party-library-sampleto generate a .tgz file. - Modify the
@react-native-oh/react-native-harmonyand@react-native-oh/react-native-harmony-clidependency path ofReactProject/package.json. - Run npm i in
ReactProjectto install the dependency. - Modify the
@rnoh/hvigor-plugindependency path ofNativeProject/hvigor/hvigor-config.json5; - Open
NativeProjectin DevEco Studio and run Sync and Refresh Project. - Click File > Project Structure > Signing Configs, log in and complete the signing.
- Run npm start in
ReactProjectto start Metro. - Click run in the upper right corner to start the project.