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
Copy file name to clipboardexpand all lines: lib/ConfigManager.ts
+4-2
Original file line number
Diff line number
Diff line change
@@ -35,16 +35,18 @@ export type ConfigManagerOptions<TData> = {
35
35
&({
36
36
/**
37
37
* Function to use to encode the data prior to saving it in persistent storage.
38
-
* The input data is a serialized JSON object.
38
+
* If this is specified, make sure to declare {@linkcode decodeData()} as well.
39
39
*
40
40
* You can make use of UserUtils' [`compress()`](https://github.com/Sv443-Network/UserUtils?tab=readme-ov-file#compress) function here to make the data use up less space at the cost of a little bit of performance.
41
+
* @param data The input data as a serialized object (JSON string)
* Function to use to decode the data after reading it from persistent storage.
45
-
* The result should be a valid JSON object.
46
+
* If this is specified, make sure to declare {@linkcode encodeData()} as well.
46
47
*
47
48
* You can make use of UserUtils' [`decompress()`](https://github.com/Sv443-Network/UserUtils?tab=readme-ov-file#decompress) function here to make the data use up less space at the cost of a little bit of performance.
49
+
* @returns The resulting data as a valid serialized object (JSON string)
0 commit comments