Skip to content

docs(swift): close integration doc gaps against SDK source [NT-3841] - #415

Open
David Nalchevanidze (nalchevanidze) wants to merge 1 commit into
mainfrom
docs/ios-sdk-guide-audit-nt-38419
Open

docs(swift): close integration doc gaps against SDK source [NT-3841]#415
David Nalchevanidze (nalchevanidze) wants to merge 1 commit into
mainfrom
docs/ios-sdk-guide-audit-nt-38419

Conversation

@nalchevanidze

Copy link
Copy Markdown
Contributor

Summary

  • Documents the contentful.swift/CTEntry typed initializer (NT-3808) in both the SwiftUI and UIKit integration guides, matching the equivalent Android guide coverage (CDAEntry typed overload).
  • Rewords the UIKit guide's screen-tracking section so trackCurrentScreen/screen are described by their actual dedupe difference, rather than a rule the guide's own reference app usage doesn't always follow.
  • Fixes the internal SDK knowledge base's stale description of TapTrackingModifier's tap mechanism (UITapGestureRecognizer on the superview, not simultaneousGesture(TapGesture())) to match the current source (NT-3829).

Test plan

  • pnpm knowledge:check passes
  • pnpm guides:check passes
  • pnpm exec prettier --check passes on all touched files
  • Docs-only change; no runtime behavior touched

🤖 Generated with Claude Code

Documents the contentful.swift/CTEntry typed initializer (NT-3808) in both
guides, matching the equivalent Android coverage; clarifies UIKit
screen()/trackCurrentScreen dedupe semantics without implying one is wrong;
and fixes the KB's stale description of TapTrackingModifier's tap mechanism.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@bito-code-review

bito-code-review Bot commented Aug 5, 2026

Copy link
Copy Markdown

Code Review Agent Run #826e19

Actionable Suggestions - 0
Additional Suggestions - 1
  • documentation/internal/sdk-knowledge/native/ios.md - 1
    • Grammar: missing relative pronoun · Line 222-222
      Minor grammatical issue: line 222 is missing a connecting word in the relative clause. Change 'without competing for touches a nested interactive child needs' to 'without competing for touches that a nested interactive child needs' to complete the subordinate clause properly.
Review Details
  • Files reviewed - 3 · Commit Range: 94a9103..94a9103
    • documentation/guides/integrating-the-optimization-ios-sdk-in-a-swiftui-app.md
    • documentation/guides/integrating-the-optimization-ios-sdk-in-a-uikit-app.md
    • documentation/internal/sdk-knowledge/native/ios.md
  • Files skipped - 0
  • Tools
    • Whispers (Secret Scanner) - ✔︎ Successful
    • Detect-secrets (Secret Scanner) - ✔︎ Successful

Bito Usage Guide

Commands

Type the following command in the pull request comment and save the comment.

  • /review - Manually triggers a full AI review.

  • /pause - Pauses automatic reviews on this pull request.

  • /resume - Resumes automatic reviews.

  • /resolve - Marks all Bito-posted review comments as resolved.

  • /abort - Cancels all in-progress reviews.

Refer to the documentation for additional commands.

Configuration

This repository uses Default Agent You can customize the agent settings here or contact your Bito workspace admin at jared.jolton@contentful.com.

Documentation & Help

AI Code Review powered by Bito Logo

@bito-code-review

Copy link
Copy Markdown

Functional Validation by Bito

SourceRequirement / Code AreaStatusNotes
NT-3808, NT-3702Document the contentful.swift CTEntry typed initializer in both the SwiftUI and UIKit integration guides, matching the equivalent Android guide coverage of CDAEntry typed overload✅ MetThe diff adds documentation for the contentful.swift CTEntry typed initializer in both integration guides. documentation/guides/integrating-the-optimization-ios-sdk-in-a-swiftui-app.md now includes a SwiftUI example showing `OptimizedEntry(entry: entry)` where developers pass `Contentful.Entry` directly and read fields with `getField()`. documentation/guides/integrating-the-optimization-ios-sdk-in-a-uikit-app.md documents the `resolveOptimizedEntry(baseline: Contentful.Entry, selectedOptimizations:)` overload with usage example. Both guides now provide parity with the Android guide's coverage of CDAEntry typed overload, closing the compatibility gap identified in NT-3808.
NT-3829Reword the UIKit integration guide's screen-tracking section so trackCurrentScreen and screen are described by their actual deduplication behavior rather than a rule the guide's own reference app usage does not consistently follow✅ MetThe diff rewrites the UIKit integration guide's screen-tracking section in documentation/guides/integrating-the-optimization-ios-sdk-in-a-uikit-app.md to accurately describe the deduplication behavior of both APIs. The updated text explains that `trackCurrentScreen` deduplicates the current route by `routeKey` (skipping repeated `viewDidAppear(_:)` calls and retrying blocked attempts), while plain `screen(name:properties:)` re-emits on every call with no dedupe for intentional one-off events or cases where every appearance should count as a fresh screen event. This reflects the actual dedupe difference rather than the previous misleading rule that the reference app did not consistently follow.
NT-3829Fix the internal SDK knowledge base's stale description of TapTrackingModifier's tap mechanism to correctly state UITapGestureRecognizer on the superview, matching the current SDK source✅ MetThe diff updates documentation/internal/sdk-knowledge/native/ios.md to correctly describe TapTrackingModifier's tap mechanism. The stale description "simultaneousGesture(TapGesture()) on the wrapper" has been replaced with the accurate implementation: on UIKit-available platforms, a plain `UITapGestureRecognizer` is attached to the wrapper's superview with `cancelsTouchesInView = false` and a delegate that always allows simultaneous recognition, avoiding competition with nested interactive children like Buttons. The entry notes this falls back to `simultaneousGesture(TapGesture())` on non-UIKit platforms like macOS. This now matches the current SDK source code.

@bito-code-review

Copy link
Copy Markdown

Impact Analysis by Bito

Code Paths Analyzed

Impact:
Documentation-only changes to iOS SDK integration guides and internal knowledge base. No functional code modifications.

Flow:
N/A - Documentation updates only

Direct Changes (Diff Files):
• documentation/guides/integrating-the-optimization-ios-sdk-in-a-swiftui-app.md [476-554] — Added SwiftUI code example for OptimizedEntry with contentful.swift Entry objects; clarified tap tracking behavior description
• documentation/guides/integrating-the-optimization-ios-sdk-in-a-uikit-app.md [457-494] — Added UIKit code example for resolveOptimizedEntry with contentful.swift Entry objects; clarified screen tracking method differences
• documentation/internal/sdk-knowledge/native/ios.md [217-228] — Updated tap tracking implementation details to reflect UITapGestureRecognizer usage

Repository Impact:
Documentation: Integration guides and internal knowledge docs updated to reflect current SDK capabilities

Cross-Repository Dependencies:
None.

Database/Caching Impact:
• None

API Contract Violations:
None.

Infrastructure Dependencies:
None.

Additional Insights:
Developer Experience: Improved documentation clarity for iOS SDK integration patterns with contentful.swift

Testing Recommendations

Frontend Impact:
None.

Service Integration:
None.

Data Serialization:
None.

Privacy Compliance:
None.

Backward Compatibility:
None.

OAuth Functionality:
• None

Reliability Testing:
• None

Additional Insights:
• Verify code examples compile correctly with latest SDK version
• Review documentation for technical accuracy against actual SDK implementation

Analysis based on known dependency patterns and edges. Actual impact may vary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants