Skip to content

Releases: Dean151/RuleKit

0.5.1

27 Jan 15:06
Compare
Choose a tag to compare

Removed unsafe flags from build target

New delay RuleOption

27 Jan 12:38
Compare
Choose a tag to compare

What's Changed

  • Add DelayOption by @divadretlaw in #1
    Thanks you so much for bringing this!

Breaking changes

  • Raised Swift 5.9 as minimum requirement
  • Rule, RuleKitOption, TriggerFrequencyOption.Frequency are now Sendable
  • condition closure for EventRule and ConditionRule are now marked with Sendable

New Contributors

Full Changelog: 0.4.1...0.5.0

Fixed setRule wrongly marked as async

12 Nov 22:50
Compare
Choose a tag to compare

The closure should be async, not the overall signature.

Asynchronous conditions

07 Nov 22:35
Compare
Choose a tag to compare

New features

  • Added ConditionRule: allowing to have simple condition throttle. Warning: rules are checked only when an event is donated.
  • ConditionRule and EventRule now take an async parameter, allowing asynchronous checking ⏲️

Breaking changes

  • Removed deprecated symbols from 0.3.x

Allowing multiple ruleset for a single Notification.Name

06 Nov 21:56
Compare
Choose a tag to compare
  • Added a name parameter to the Notification trigger. Each unique name will register as independent triggers, and will allow different rules for frequency, and triggers.
  • Added a bit more inline documentation to available methods and parameters.

Fixed result builder

02 Nov 20:27
Compare
Choose a tag to compare

This is a fix release:

  • Added back the 2.x signature for building rules
  • Fixed the new result builder introduced in 0.3.0, that was broken by default
  • Added tests for the public interface :D

Closure triggers!

01 Nov 17:24
Compare
Choose a tag to compare

Closures!

You may now register a closure instead of a NSNotification.Name to being triggered by RuleKit.
A closure requires a unique name to be provided for triggers history storage.

await RuleKit.setRule(triggering: {
    showPaywall = true
}, rawValue: "showPaywall", options: [.triggerFrequency(.hourly)], .anyOf {
    EventRule(event: .appOpened) {
        Premium.currentOffering.name == "sales"
    }
})

Breaking changes

  • Deleted deprecated RuleKit.Event.resetDonation() in favor of RuleKit.Event.resetDonations()

Improved interfaces

19 Sep 21:57
Compare
Choose a tag to compare

Most of the public structs are now under the RuleKit namespace, because some names like "Event" are too common.
Also added an example documentation

Initial release!

17 Sep 15:10
Compare
Choose a tag to compare

First release for RuleKit!

Needed a TipKit style set of rule for triggering a behavior in your app?
Here it is!