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
@@ -120,6 +120,13 @@ The SDK supports the operations `set`, `setOnce`, `unset`, and `add` on individu
120
120
amplitude.identify(identify);
121
121
```
122
122
123
+
6.`prepend`:this will prepend a value or values to a user property. If the user property does not have a value set yet, it will be initialized to an empty list before the newvalues are prepended. If the user property has an existing value and it is not a list, it will be converted into a list with the newvalue prepended.
124
+
125
+
```javascript
126
+
var identify = new amplitude.Identify().prepend('ab-tests', 'new-user-test').prepend('some_list', [1, 2, 3, 4, 'values']);
127
+
amplitude.identify(identify);
128
+
```
129
+
123
130
Note:if a user property is used in multiple operations on the same `Identify` object, only the first operation will be saved, and the rest will be ignored. Inthis example, only the set operation will be saved, and the add and unset will be ignored:
0 commit comments