Skip to content

Commit ed93075

Browse files
authored
feat: [FFM-10875]: Update Javascript Client SDK to v1.25.0 (#16)
1 parent ea87649 commit ed93075

File tree

4 files changed

+32
-18
lines changed

4 files changed

+32
-18
lines changed

README.md

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,24 @@ from the server behind the scenes.
131131
The `cache` option can also be passed as an object with the following options.
132132

133133
```typescript
134-
export interface CacheOptions {
135-
ttl?: number // maximum age of stored cache, in ms, before it is considered stale
134+
interface CacheOptions {
135+
// maximum age of stored cache, in ms, before it is considered stale
136+
ttl?: number
137+
// storage mechanism to use, conforming to the Web Storage API standard, can be either synchronous or asynchronous
138+
// defaults to localStorage
139+
storage?: AsyncStorage | SyncStorage
140+
}
141+
142+
interface SyncStorage {
143+
getItem: (key: string) => string | null
144+
setItem: (key: string, value: string) => void
145+
removeItem: (key: string) => void
146+
}
147+
148+
interface AsyncStorage {
149+
getItem: (key: string) => Promise<string | null>
150+
setItem: (key: string, value: string) => Promise<void>
151+
removeItem: (key: string) => Promise<void>
136152
}
137153
```
138154

@@ -175,8 +191,6 @@ function MyComponent() {
175191
baseUrl: 'https://url-to-access-flags.com',
176192
eventUrl: 'https://url-for-events.com',
177193
streamEnabled: true,
178-
allAttributesPrivate: false,
179-
privateAttributeNames: ['customAttribute'],
180194
debug: true,
181195
eventsSyncInterval: 60000
182196
}}

examples/get-started/package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package-lock.json

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@harnessio/ff-react-client-sdk",
3-
"version": "1.8.1",
3+
"version": "1.9.0",
44
"author": "Harness",
55
"license": "Apache-2.0",
66
"module": "dist/esm/index.js",
@@ -21,7 +21,7 @@
2121
"react": ">=16.7.0"
2222
},
2323
"dependencies": {
24-
"@harnessio/ff-javascript-client-sdk": "^1.23.0",
24+
"@harnessio/ff-javascript-client-sdk": "^1.25.0",
2525
"lodash.omit": "^4.5.0"
2626
},
2727
"devDependencies": {

0 commit comments

Comments
 (0)