You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs: update iOS SDK docs for non-throwing assignment methods (#692)
Remove try keyword from getStringAssignment, getBooleanAssignment,
getIntegerAssignment, getNumericAssignment, and getJSONStringAssignment
method calls since these methods no longer throw exceptions.
Copy file name to clipboardExpand all lines: docs/sdks/client-sdks/ios/assignments.mdx
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,7 +40,7 @@ getJSONStringAssignment(...)
40
40
String assignments return a string value that is set as the variation for the experiment. String flags are the most common type of flags and are useful for both A/B/n tests and advanced targeting use cases.
41
41
42
42
```swift
43
-
let assignment =tryeppoClient.getStringAssignment(
43
+
let assignment = eppoClient.getStringAssignment(
44
44
flagKey: "new-user-onboarding",
45
45
subjectKey: user.id,
46
46
subjectAttributes: user.attributes,
@@ -63,7 +63,7 @@ default:
63
63
Boolean flags support simple on/off toggles. They're useful for simple, binary feature switches like blue/green deployments or enabling/disabling a new feature.
64
64
65
65
```swift
66
-
let isEnabled =tryeppoClient.getBooleanAssignment(
66
+
let isEnabled = eppoClient.getBooleanAssignment(
67
67
flagKey: "new-feature",
68
68
subjectKey: user.id,
69
69
subjectAttributes: user.attributes,
@@ -83,15 +83,15 @@ The SDK supports both integer and numeric assignments. These are useful for test
83
83
84
84
```swift
85
85
// Integer assignment
86
-
let itemCount =tryeppoClient.getIntegerAssignment(
86
+
let itemCount = eppoClient.getIntegerAssignment(
87
87
flagKey: "items-per-page",
88
88
subjectKey: user.id,
89
89
subjectAttributes: user.attributes,
90
90
defaultValue: 10
91
91
)
92
92
93
93
// Numeric assignment
94
-
let price =tryeppoClient.getNumericAssignment(
94
+
let price = eppoClient.getNumericAssignment(
95
95
flagKey: "subscription-price",
96
96
subjectKey: user.id,
97
97
subjectAttributes: user.attributes,
@@ -112,7 +112,7 @@ let defaultConfig = """
112
112
}
113
113
"""
114
114
115
-
let config =tryeppoClient.getJSONStringAssignment(
0 commit comments