Releases: superwall/Superwall-iOS
2.5.4
2.5.3
2.5.2
You know when app devs are lazy and just put "bug fixes and performance improvements" in their release notes? Well this release contains bug fixes and performance improvements... for real though!
Fixes
- Fixed memory and performance issues associated with the shimmer view when loading a paywall. Special thanks to Mattias from Planta for spotting that one and Jakub from Hornet for helping us solve performance issues. We've rebuilt the shimmer view and only add it when the paywall is visible and loading. This means it doesn't get added to paywalls preloading in the background. After loading, we remove the shimmer view from memory.
- Moves internal operations for templating paywall variables from the main thread to a background thread. This prevents hangs on the main thread.
- Stops
UIAlertViewControllers
being unnecessarily created when loading a paywall. - Removes the dependency on
TPInAppReceipt
from our podspec and replaces it with aASN1Swift
dependency to keep it in line with our Swift Package file. Thanks to Semyon from Appex for spotting that!
2.5.0
Enhancements
- Assigments of paywall variants are now performed on device, meaning reduced network calls and faster setup time for the SDK.
- Adds
Paywall.latestPaywallInfo
. You can read this to access thePaywallInfo
object of the most recently presented view controller. - Adds feature flags under the hood so new features can be turned on for specific organizations and apps.
- Adds the ability to specify
SKProducts
with triggers. These override products defined in the dashboard. You do this by creating aPaywallProducts
object and callingPaywall.trigger(event: "event", products: products)
. - Updates sample projects to iOS 16.
Fixes
- Shimmer view is no longer visible beneath a paywall's
WKWebView
when there is nobody
orhtml
background color set - Previously, calling
Paywall.preloadPaywalls(forTriggers:)
beforePaywall.config()
finished would not work. This has been fixed. - Previously, if a user purchases a product within a subscription group, they would still be offered a free trial on other products within that group. This has been fixed.
- Fixes a bug where
Paywall.reset()
couldn't be called on a background thread.
2.4.1
Enhancements
- Adds
Paywall.preloadAllPaywalls()
andPaywall.preloadPaywalls(forTriggers:)
. Use this withPaywall.options.shouldPreloadPaywall = false
to have more control over when/what paywalls are preloaded.
Fixes
- Paywall options specified prior to config are now respected, regardless of whether you pass an options object through to config or not.
- Ensures /config's request and response is always handled on the main thread
2.4.0
Enhancements
- New push presentation style. By selecting Push on the superwall dashboard, your paywall will push and pop in as if it's being pushed/popped from a navigation controller. If you are using UIKit, you can provide a view controller to
Paywall.trigger
like this:Paywall.trigger(event: "MyEvent", on: self)
. This will make the push transition more realistic, by moving its view in the transition. Note: This is not backwards compatible with previous versions of the SDK. - New no animation presentation style. By selecting No Animation in the superwall dashboard, you can disable presentation/dismissal animation. This release deprecates
Paywall.shouldAnimatePaywallDismissal
andPaywall.shouldAnimatePaywallPresentation
. - A new
PaywallOptions
object that you configure and pass to `Paywall.configure(apiKey:userId:delegate:options) to override the default appearance and presentation of the paywall. This deprecates a lot of static variables for better organisation. - New
shouldPreloadPaywalls
option. Set this tofalse
to make paywalls load and cache in a just-in-time fashion. This replaces the oldPaywall.shouldPreloadTriggers
flag. - New dedicated function for handling deeplinks:
Paywall.handleDeepLink(url)
. - Deprecates old
track
functions. The only one you should use isPaywall.track(_:_:)
, to which you pass an event name and a dictionary of parameters. Note: This is not backwards compatible with previous versions of the SDK. - Adds a new way of internally tracking analytics associated with a paywall and the app session. This will greatly improve the Superwall dashboard analytics.
- Adds support for javascript expressions defined in rules on the Superwall dashboard.
- Updates the SDK documentation.
- Adds
trialPeriodEndDate
as a product variable. This means you can tell your users when their trial period will end, e.g.Start your trial today — you won't be billed until {{primary.trialPeriodEndDate}}
will print outStart your trial today — you won't be billed until June 21, 2023
. - Adds support for having more than 3 products on your paywall.
- Exposes
Paywall.presentedViewController
. This gives you access to theUIViewController
of the paywall incase you need to present a view controller on top of it. - Adds
today
,daysSinceInstall
,minutesSinceInstall
,daysSinceLastPaywallView
,minutesSinceLastPaywallView
andtotalPaywallViews
asdevice
parameters. These can be references in your rules and paywalls with{{ device.paramName }}
. - Paywalls can now be configured via the dashboard to always present, regardless of the subscription status of the user.
- Adds a
presentationStyleOverride
parameter toPaywall.trigger()
andPaywall.present()
. By setting this, you can override the configured presentation style on case by case basis. - Rules can now be limited by occurrence and date. For example, you could set a rule to only match 10 times within the last 5 hours.
- Adds
Paywall.userId
to grab the id of the current user. - Adds
$url
,$path
,$pathExtension
,$lastPathComponent
,$host
,$query
,$fragment
as standard parameters to thedeepLink_open
event trigger (automatically tracked). - Parses URL parameters and adds them as trigger parameters to the
deepLink_open
event trigger (automatically tracked). - Fixes window logic for opening the debugger and launching paywalls on
deepLink_open
. - Launching a paywall using the
deepLink_open
Trigger now dismisses a currently presenting paywall before presenting the new one.
Fixes
- Adds the missing Superwall events
app_install
,paywallWebviewLoad_fail
,paywallWebviewLoad_timeout
andnonRecurringProduct_purchase
. - Adds
trigger_name
to atriggerFire
Superwall event, which can be accessed in the parameters sent back to thetrackAnalyticsEvent(name:params:)
delegate function. - Product prices were being sent back to the dashboard with weird values like 89.999998. We fixed that.
- Modal presentation now uses
.pageSheet
instead of.formSheet
. This results in a less compact paywall popover on iPad. Thanks to Daniel Yoo from the Daily Bible Inspirations app for spotting that! - For SwiftUI users, we've fixed an issue where the explicitly triggered paywalls and presented paywalls would sometimes randomly dismiss. We found that state changes within the presenting view caused a rerendering of the view which temporarily reset the state of the binding that controlled the presentation of the paywall. This was causing the Paywall to dismiss.
- Fixes an issue where the wrong paywall was shown if a trigger was fired before the config was fetched from the server. Thanks to Zac from Blue Candy for help with finding that :)
- Future proofs enums internally to increase backwards compatibility.
- Fixes a bug where long term data was being stored in the cache directory. This update migrates that to the document directory. This means the data stays around until we tell it to delete, rather than the system deleting it at random.
- Prevents Paywall.configure from being called twice and logs a warning if this occurs.
- Prevents Paywall.configure from being called in the background.
- Fixes an issue where the keyboard couldn't be dismissed in the UIKit sample app.
- Mentions SwiftLint as a requirement to run the sample apps.
- Deprecates
Paywall.debugMode
. All logs are now controlled by setting the paywall option.logLevel
. The defaultlogLevel
is now.warn
. - Fixes broken webview based deeplinks and closes the paywall view before calling the delegate handler.
- Deprecates
Paywall.present
forPaywall.trigger
. - Fixes issue where preloaded paywalls would be cleared upon calling
Paywall.identify()
if config was called without auserId
. - Fixes logic for grabbing the active view controller.
2.3.0
What's New
- New UIKit Example App.
- Better SDK documentation. This is built from the ground up using DocC which means you view it directly in Xcode by selecting Product ▸ Build Documentation.
- New Pull Request and Bug Report templates for the repo.
- Added a setup file that installs GitHooks as well as SwiftLint if you don't already have it. This is located at
scripts/setup.sh
and can be run from anywhere. - Added a CONTIBUTING.md file for detailed instructions on how to get set up and contribute to the codebase.
- Added a Code of Conduct file to the repo.
- Added a CHANGELOG.md file.
- Removed the
TPInnAppReceipt
dependency for the SDK.
Fixes
- All readme links for the UIKit example app now work.
- Adds an
experiment
parameter toPaywallInfo
. This will be useful in the next version of Triggers, where you can see details about the experiment that triggered the presentation of the paywall. - When triggering or presenting a paywall, if the default value for
isPresented
wastrue
, the paywall would not present/trigger. It now works as expected.
2.2.10
What's New:
2.2.10
brings tons of speed / reliability improvements. @anglinb has been hard at work making sure paywall responses cache on the edge. This means a reduced load on our end and much quicker API responses in general.
This release also adds support for TriggersV2 (still in beta, name not final, let us know if you want access). TriggersV2 lets you
- create sets of rules under a trigger for when paywalls should be presented.
- add weights to paywalls within rules (for example, when
onboarding_complete
is triggered, if age < 30, showPaywall A
5% of the time,Paywall B
5% of the time,Do Nothing
90% of the time)
This is also @yusuftor'f first release. Yusuf, thank you for raising the bar at Superwall. Your attention to detail and willingness to roll up your sleeves & get sh*t done does not go unnoticed — welcome to the fam :)
Adds
- triggersV2
- paywalls now load as GET requests by identifier (and are cached on the edge)
- paywalls called via triggers and
Paywall.present()
load faster now - more robust caching by reworking cache key logic
- SwiftUI example app (s/o @yusuftor)
- big code cleanup and refactor (s/o @yusuftor)
- paywall load time parameters to related analytics events
- bundleId to request headers
- adds minimum version check of 12.2 for
SWProductDiscount
(s/o to Maté)
2.2.7
What's New
Adds:
- adds
$isStandardEvent: true
param to all standard events tracked by the SDK - adds event data to paywall open / close events
- adds pre-fetching & caching of all possible paywalls that may be shown to the user
- adds ability to reference
user
anddevice
in liquid syntax while editing text variables in a paywalls - adds workflow that creates new branch for every release and version
- adds iOS 10 support
- adds pre-caching of paywalls referenced in triggers by default. You can shut this off if you want.
Fixes:
- fixes presenting a view controller on
nil
inSceneDelegate
based projects - fixes a bug preventing the presentation of a paywall on app launch
- fixes
onDismiss
callback for modally presented paywalls - fixes
GameController
support for iOS 13 devices
Removes:
- removes docs from the main branch
- removes extraneous print statements
Installation Instructions:
CocoPods:
// From your terminal:
$ pod repo update
// In your Podfile
pod 'Paywall', "~> 2.2.7"
// From your terminal, again 🥳
$ pod install
SPM:
- To update all your packages
- Xcode > File > Packages > Update to Latest Package Versions
- To update only Superwall
- Open Xcode
- Select your project in the project navigator
- Make sure your project is selected (not your Target!)
- Select Package Dependencies
- Double click on your
Paywall
package - Set Version to
Exact
and equal to2.2.7