Skip to content

Document OptableTargeting, async/await and Prebid integration - #80

Merged
jrosendahl-opt merged 5 commits into
masterfrom
docs/targeting-prebid-async
Oct 30, 2026
Merged

jrosendahl-opt merged 5 commits into
masterfrom
docs/targeting-prebid-async

Conversation

@jrosendahl-opt

@jrosendahl-opt jrosendahl-opt commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Why

The guides don't describe the OptableTargeting object that targeting, profile and targetingFromCache return, including what gamTargetingKeywords and ortb2 contain. They don't mention the Swift async APIs either, and neither has a Prebid Mobile section, even though both demo apps integrate Prebid.

Part of a series of small PRs bringing the README, guides and demo apps back in line with the code (follows #74–#79).

Describe the OptableTargeting properties and how gamTargetingKeywords
and ortb2 are derived, add the async/await variants to the Swift guide,
and add a Prebid Mobile integration section to both guides based on the
demo apps.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jrosendahl-opt
jrosendahl-opt requested review from a team as code owners October 28, 2026 15:54

@mosherBT mosherBT left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comments

Comment thread docs/usage-swift.md Outdated
Comment on lines +321 to +326
bannerAdUnit.fetchDemand(adObject: adRequest) { _ in
DispatchQueue.main.async {
bannerView.load(adRequest)
}
}
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
bannerAdUnit.fetchDemand(adObject: adRequest) { _ in
DispatchQueue.main.async {
bannerView.load(adRequest)
}
}
}
bannerAdUnit.fetchDemand(adObject: adRequest) { [weak self] _ in
DispatchQueue.main.async {
self?.bannerView.load(adRequest)
}
}
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Comment thread docs/usage-swift.md Resolved
Comment thread docs/usage-objc.md Resolved
jrosendahl-opt and others added 4 commits October 30, 2026 09:00
Co-authored-by: mosherBT <115997271+mosherBT@users.noreply.github.com>
Co-authored-by: mosherBT <115997271+mosherBT@users.noreply.github.com>
The fetchDemand completion kept the owning view controller alive until
Prebid answered. Capture it weakly, and say up front that bannerAdUnit
and bannerView are properties of the class, since the code uses self.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jrosendahl-opt
jrosendahl-opt merged commit 30158ca into master Oct 30, 2026
4 checks passed
@jrosendahl-opt
jrosendahl-opt deleted the docs/targeting-prebid-async branch October 30, 2026 16:27
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