要在 firebase 中应用的产品包标识符名称

Product Bundle Identifier name to apply in firebase

我正在研究有关如何使用 React Native 和 firebase 构建 iOS 应用程序的教程,他们总能获得捆绑包 iOS。在我的例子中,因为我使用的是 windows,我去了 project.pbxproj 文件并搜索 bundle 并找到了这个。

 PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
                PRODUCT_NAME = "$(TARGET_NAME)";
                TEST_HOST = "$(BUILT_PRODUCTS_DIR)/firebase.app/firebase";

通常在product_bundle_identifier,他们只有喜欢"org.reactjs.native.example"。 你认为我必须删除美元符号后面的内容吗,或者我可以将“org.reactjs.native.example”放在 firebase 上并且它会起作用?

不应 修改任何关于 PRODUCT_BUNDLE_IDENTIFIER 的内容。嗯……好吧,也许你可以,但没必要。你所拥有的是 Xcode 如何构建最终包 ID 的说明,因此你可以重播它们以获得相同的值。

查看您的 PRODUCT_NAME 是什么(参见 here and here) and then funnel that through a rfc1034identifier "filter" (pretty much replacing spaces and dots with _, as explained here and here。这将为您提供需要在 Firebase 中指定的最终包 ID。