refactor: tighten inline comments across the native bridge
Keeps the non-obvious rationale (pod naming, repository injection, one-shot promise settling, optional guards) and drops restatements of what the code already shows.
| ... | ... | @@ -2,11 +2,9 @@ require "json" |
| package = JSON.parse(File.read(File.join(__dir__, "package.json"))) | ||
| # The pod is deliberately NOT named "MyidSdk": that differs from the vendor pod | ||
| # "MyIdSDK" only by case, and on a case-insensitive filesystem the two targets | ||
| # collide on the same intermediate build directory, so this pod's generated | ||
| # Swift header lands in the vendor's build dir and the ObjC++ layer cannot | ||
| # import it. The JS module name is unaffected and stays "MyidSdk". | ||
| # Not named "MyidSdk": that differs from the vendor pod "MyIdSDK" only by case, | ||
| # and on a case-insensitive filesystem both targets share one build directory, | ||
| # leaving this pod's generated Swift header where ObjC++ cannot import it. | ||
| Pod::Spec.new do |s| | ||
| s.name = "RNMyidSdk" | ||
| s.version = package["version"] | ||
| ... | ... | @@ -21,12 +19,11 @@ Pod::Spec.new do |s| |
| s.source_files = "ios/**/*.{h,m,mm,swift,cpp}" | ||
| s.private_header_files = "ios/**/*.h" | ||
| # Binary XCFramework distributed on the public CocoaPods trunk. | ||
| s.dependency "MyIdSDK", "3.1.3" | ||
| s.swift_version = "5.0" | ||
| # DEFINES_MODULE lets the ObjC++ layer import the generated RNMyidSdk-Swift.h. | ||
| # Lets the ObjC++ layer import the generated RNMyidSdk-Swift.h. | ||
| s.pod_target_xcconfig = { "DEFINES_MODULE" => "YES" } | ||
| install_modules_dependencies(s) | ||
| ... | ... |
Please register or sign in to comment