-
Notifications
You must be signed in to change notification settings - Fork 316
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PaywallsTester: add a new tab that calls presentPaywallIfNeeded #3259
PaywallsTester: add a new tab that calls presentPaywallIfNeeded #3259
Conversation
@@ -108,7 +115,7 @@ struct AppContentView: View { | |||
if let stream = self.customerInfoStream { | |||
for await info in stream { | |||
self.customerInfo = info | |||
self.showingDefaultPaywall = info.activeSubscriptions.count == 0 | |||
self.showingDefaultPaywall = self.showingDefaultPaywall && info.activeSubscriptions.count == 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops this was a bug in #3256, it would still show the paywall every time 😅
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3259 +/- ##
==========================================
- Coverage 85.93% 85.92% -0.02%
==========================================
Files 233 233
Lines 16657 16657
==========================================
- Hits 14315 14313 -2
- Misses 2342 2344 +2 ☔ View full report in Codecov by Sentry. |
import SwiftUI | ||
|
||
struct UpsellView: View { | ||
var body: some View { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: space per our style guide.
This is achieved by calling | ||
`.presentPaywallIfNeeded(requiredEntitlementIdentifier: \(Configuration.entitlement)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love it. Small typo:
This is achieved by calling | |
`.presentPaywallIfNeeded(requiredEntitlementIdentifier: \(Configuration.entitlement)) | |
This is achieved by calling | |
`.presentPaywallIfNeeded(requiredEntitlementIdentifier: \(Configuration.entitlement))` |
|
||
struct UpsellView: View { | ||
var body: some View { | ||
VStack { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't needed right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I planned on adding more things initially, but never got around to it. I can remove this for now
f18e551
to
7ebd5fd
Compare
**This is an automatic release.** ### New Features * Add `Attribution.setOnesignalUserID` (#3268) via Raquel Diez (@Raquel10-RevenueCat) * StoreKit In App messages support (#3252) via Toni Rico (@tonidero) ### Other Changes * Remove ObjC showStoreMessages API (#3269) via Toni Rico (@tonidero) * PaywallsTester: add a new tab that calls presentPaywallIfNeeded (#3259) via Andy Boedo (@aboedo) * `Paywalls`: small PaywallsTester refactor (#3261) via NachoSoto (@NachoSoto)
Adds a new tab that calls
presentPaywallIfNeeded