1.0.0 • Published 6 years ago

react-native-short-video v1.0.0

Weekly downloads
-
License
ISC
Repository
-
Last release
6 years ago

安装、配置

  1. 安装 : $npm install react-native-short-video --save
  2. 链接 : $npm link
  3. 用XCode打开react native项目, 将node_modules --> react-native-short-video --> ios --> ShortVideo.xcodeproj拖入到Libraries文件夹
  4. 将react-native-short-video --> resource和shortVideoSDK中的所有文件添加到工程ios根目录下
  5. 集成cocoapods. $pod init $pod install 在Podfile中添加以下第三方库然后 $pod install
    ```
    target '项目名' do
        pod 'KSYMediaEditorKit', '~> 2.1.0'
        pod 'AFNetworking', '~> 3.1.0'
        pod 'MBProgressHUD', '~> 0.9.2'
        pod 'BlocksKit', '~> 2.2.5'
        pod 'MJExtension', '~> 3.0.10'
    end
    ```

使用

import ShortVideoView from './shortVideo';

render() {

    return(
        <View style={{flex:1,justifyContent:'center',alignItems:'center'}}>
            <ShortVideoView style={{height:deviceHeight,width:deviceWidth}}/>
        </View>
        )
}