Latest 0.0.1
Homepage https://github.com/duanruiying/DryGoogle
License MIT
Platforms ios 10.0, requires ARC
Dependencies GoogleSignIn
Frameworks UIKit, Foundation
Authors

iOS: Facebbok功能集成简化(登录)

Prerequisites

  • Xcode 10.2.1
  • iOS 10.0 or later
  • ObjC、Swift

Installation

  • pod ‘DryGoogle’

App工程配置

  • 为URL Types 添加回调scheme(identifier:""、URL Schemes:"com.googleusercontent.apps.+AppID")

Features

SDK配置

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
    [DryGoogle registerSDK:@""];
    return YES;
}

- (BOOL)application:(UIApplication *)app openURL:(NSURL *)url options:(NSDictionary<UIApplicationOpenURLOptionsKey,id> *)options {
    [DryGoogle handleOpenURL:url options:options];
    return YES;
}

登录、获取用户信息

/// 登录
[DryGoogle login:^(DryGoogleCode code, DryGoogleUser * _Nullable user) {
    NSLog(@"%ld", (long)code);

    /// 获取用头像数据
    [DryGoogle userAvatar:50 completion:^(UIImage * _Nullable img, NSURL * _Nullable url) {
        NSLog(@"%@", url);
    }];
}];

Latest podspec

{
    "name": "DryGoogle",
    "version": "0.0.1",
    "summary": "DryGoogle",
    "homepage": "https://github.com/duanruiying/DryGoogle",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "duanruiying": "[email protected]"
    },
    "source": {
        "git": "https://github.com/duanruiying/DryGoogle.git",
        "tag": "0.0.1"
    },
    "description": "TODO: Googleu529fu80fdu7b80u5316(u767bu5f55u3001u83b7u53d6u7528u6237u4fe1u606f).",
    "platforms": {
        "ios": "10.0"
    },
    "requires_arc": true,
    "user_target_xcconfig": {
        "OTHER_LDFLAGS": [
            "-w"
        ]
    },
    "static_framework": true,
    "pod_target_xcconfig": {
        "OTHER_LDFLAGS": [
            "-w",
            "-ObjC"
        ]
    },
    "source_files": "DryGoogle/Classes/Code/**/*",
    "public_header_files": "DryGoogle/Classes/Code/Public/**/*.h",
    "libraries": "z",
    "frameworks": [
        "UIKit",
        "Foundation"
    ],
    "dependencies": {
        "GoogleSignIn": []
    }
}

Pin It on Pinterest

Share This