Google Analytics Pod会安装太多的依赖项 [英] Google Analytics Pod installs too many dependencies

查看:170
本文介绍了Google Analytics Pod会安装太多的依赖项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚列入Google Analytics Pod,详情请参阅其iOS开发人员指南

I've just included the Google Analytics Pod as described in their iOS developer guide with:

pod 'Google/Analytics'

运行时

pod install

它会安装以下依赖项:

it installs the following dependencies:

Installing FirebaseAnalytics (3.2.0)
Installing FirebaseInstanceID (1.0.6)
Installing Google (3.0.3)
Installing GoogleAnalytics (3.14.0)
Installing GoogleInterchangeUtilities (1.2.1)
Installing GoogleSymbolUtilities (1.1.1)
Installing GoogleUtilities (1.3.1)

因为我没有使用Firebase,我想摆脱 FirebaseAnalytics FirebaseInstanceID (以及框架本身不需要的所有豆荚)。

Since I don't use Firebase, I would like to get rid of the FirebaseAnalytics and FirebaseInstanceID (as well as all pods that are not needed by the framework itself).

安装未使用的依赖cies只会扩大我的应用程序大小。我只想安装绝对最低数量的广告连播,以便GoogleAnalytics正常运行

Installing unused dependencies only bloats up my app size. I would like to only install the absolute minimum amount of pods to get GoogleAnalytics running.

关于如何将未使用的广告Pod踢出的想法?

Any ideas on how to kick the unused Pods out?

推荐答案

正如这个答案,您可以使用:

As seen in this answer, you can use:

pod 'GoogleAnalytics'

...以避免安装依赖项。请注意,您需要在桥接头文件中更改您的Objective-C导入;我至少需要:
$ b

…to avoid installing the dependencies. Note that you'll need to change your Objective-C imports in your bridging header file; I needed at least:

#import <GoogleAnalytics/GAI.h>
#import <GoogleAnalytics/GAIFields.h>
#import <GoogleAnalytics/GAIDictionaryBuilder.h>

这篇关于Google Analytics Pod会安装太多的依赖项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆