@sv443-network/userutils 9.2.0 → 9.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -1
- package/README-summary.md +1 -1
- package/README.md +1 -1
- package/dist/index.global.js +1 -1
- package/dist/lib/DataStoreSerializer.d.ts +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @sv443-network/userutils
|
|
2
2
|
|
|
3
|
+
## 9.2.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 24dad2b: Fixed TS type for `DataStoreSerializer.serialize()`
|
|
8
|
+
|
|
3
9
|
## 9.2.0
|
|
4
10
|
|
|
5
11
|
### Minor Changes
|
|
@@ -11,7 +17,7 @@
|
|
|
11
17
|
- 905fea4: Added function `onDomLoad()` to call a callback and/or resolve a Promise when the DOM is loaded, even retroactively
|
|
12
18
|
- 4264154: Added function `bitSetHas()` to check if a given value is present in a [bitset](https://www.geeksforgeeks.org/cpp-bitset-and-its-application/)
|
|
13
19
|
- bf55335: Replaced a bunch of generic `Error`s with the new custom error class instances
|
|
14
|
-
- bf55335: Added custom error classes `ChecksumMismatchError`, `
|
|
20
|
+
- bf55335: Added custom error classes `ChecksumMismatchError`, `MigrationError` and `PlatformError`, extending from the base class `UUError`
|
|
15
21
|
The base class has the additional property `date` which is the time of the error creation
|
|
16
22
|
|
|
17
23
|
### Patch Changes
|
package/README-summary.md
CHANGED
|
@@ -109,7 +109,7 @@ View the documentation of previous major releases:
|
|
|
109
109
|
- **Custom Error classes:**
|
|
110
110
|
- [`UUError`](https://github.com/Sv443-Network/UserUtils/blob/main/docs.md#uuerror) - base class for all custom UserUtils errors - has a custom `date` prop set to the time of creation
|
|
111
111
|
- [`ChecksumMismatchError`](https://github.com/Sv443-Network/UserUtils/blob/main/docs.md#checksummismatcherror) - thrown when a string of data doesn't match its checksum
|
|
112
|
-
- [`
|
|
112
|
+
- [`MigrationError`](https://github.com/Sv443-Network/UserUtils/blob/main/docs.md#migrationerror) - thrown when a data migration fails
|
|
113
113
|
- [`PlatformError`](https://github.com/Sv443-Network/UserUtils/blob/main/docs.md#platformerror) - thrown when a function is called in an unsupported environment
|
|
114
114
|
|
|
115
115
|
<br><br>
|
package/README.md
CHANGED
|
@@ -112,7 +112,7 @@ View the documentation of previous major releases:
|
|
|
112
112
|
- [**Custom Error classes**](./docs.md#error-classes)
|
|
113
113
|
- [`UUError`](./docs.md#uuerror) - base class for all custom UserUtils errors - has a custom `date` prop set to the time of creation
|
|
114
114
|
- [`ChecksumMismatchError`](./docs.md#checksummismatcherror) - thrown when a string of data doesn't match its checksum
|
|
115
|
-
- [`
|
|
115
|
+
- [`MigrationError`](./docs.md#migrationerror) - thrown when a data migration fails
|
|
116
116
|
- [`PlatformError`](./docs.md#platformerror) - thrown when a function is called in an unsupported environment
|
|
117
117
|
|
|
118
118
|
<br><br>
|
package/dist/index.global.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
// ==UserLibrary==
|
|
9
9
|
// @name UserUtils
|
|
10
10
|
// @description General purpose DOM/GreaseMonkey library that allows you to register listeners for when CSS selectors exist, intercept events, create persistent & synchronous data stores, modify the DOM more easily and much more
|
|
11
|
-
// @version 9.2.
|
|
11
|
+
// @version 9.2.1
|
|
12
12
|
// @license MIT
|
|
13
13
|
// @copyright Sv443 (https://github.com/Sv443)
|
|
14
14
|
|
|
@@ -48,13 +48,13 @@ export declare class DataStoreSerializer {
|
|
|
48
48
|
* @param useEncoding Whether to encode the data using each DataStore's `encodeData()` method
|
|
49
49
|
* @param stringified Whether to return the result as a string or as an array of `SerializedDataStore` objects
|
|
50
50
|
*/
|
|
51
|
-
serialize(useEncoding
|
|
51
|
+
serialize(useEncoding?: boolean, stringified?: true): Promise<string>;
|
|
52
52
|
/**
|
|
53
53
|
* Serializes the data stores into a string.
|
|
54
54
|
* @param useEncoding Whether to encode the data using each DataStore's `encodeData()` method
|
|
55
55
|
* @param stringified Whether to return the result as a string or as an array of `SerializedDataStore` objects
|
|
56
56
|
*/
|
|
57
|
-
serialize(useEncoding
|
|
57
|
+
serialize(useEncoding?: boolean, stringified?: false): Promise<SerializedDataStore[]>;
|
|
58
58
|
/**
|
|
59
59
|
* Deserializes the data exported via {@linkcode serialize()} and imports it into the DataStore instances.
|
|
60
60
|
* Also triggers the migration process if the data format has changed.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sv443-network/userutils",
|
|
3
3
|
"libName": "UserUtils",
|
|
4
|
-
"version": "9.2.
|
|
4
|
+
"version": "9.2.1",
|
|
5
5
|
"description": "General purpose DOM/GreaseMonkey library that allows you to register listeners for when CSS selectors exist, intercept events, create persistent & synchronous data stores, modify the DOM more easily and much more",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.js",
|