@boltstore/utils 0.5.0 → 0.5.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/README.md +20 -20
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
# @boltstore/
|
|
1
|
+
# @boltstore/utils
|
|
2
2
|
|
|
3
3
|
Shared TypeScript types, validation, and utilities for Boltstore. Zero dependencies. Tree-shakeable.
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
npm install @boltstore/
|
|
8
|
+
npm install @boltstore/utils
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
## Usage
|
|
@@ -14,19 +14,19 @@ npm install @boltstore/shared
|
|
|
14
14
|
|
|
15
15
|
```ts
|
|
16
16
|
// Only auth types are bundled
|
|
17
|
-
import { JwtPayload, ApiKeyClaims } from "@boltstore/
|
|
17
|
+
import { JwtPayload, ApiKeyClaims } from "@boltstore/utils/auth-types";
|
|
18
18
|
|
|
19
19
|
// Only validation functions are bundled
|
|
20
|
-
import { validateField, validateRecord } from "@boltstore/
|
|
20
|
+
import { validateField, validateRecord } from "@boltstore/utils/validation";
|
|
21
21
|
|
|
22
22
|
// Only filter parser is bundled
|
|
23
|
-
import { parseFilter, parseQuery } from "@boltstore/
|
|
23
|
+
import { parseFilter, parseQuery } from "@boltstore/utils/filter";
|
|
24
24
|
|
|
25
25
|
// Only sync types
|
|
26
|
-
import { VersionVector, MergeResult } from "@boltstore/
|
|
26
|
+
import { VersionVector, MergeResult } from "@boltstore/utils/sync-types";
|
|
27
27
|
|
|
28
28
|
// Only constants
|
|
29
|
-
import { ErrorCodes, Limits } from "@boltstore/
|
|
29
|
+
import { ErrorCodes, Limits } from "@boltstore/utils/constants";
|
|
30
30
|
```
|
|
31
31
|
|
|
32
32
|
### Convenience barrel (imports everything)
|
|
@@ -38,23 +38,23 @@ import {
|
|
|
38
38
|
validateField,
|
|
39
39
|
parseFilter,
|
|
40
40
|
ErrorCodes,
|
|
41
|
-
} from "@boltstore/
|
|
41
|
+
} from "@boltstore/utils";
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
## Exports
|
|
45
45
|
|
|
46
|
-
| Entrypoint
|
|
47
|
-
|
|
48
|
-
| `@boltstore/
|
|
49
|
-
| `./types`
|
|
50
|
-
| `./validation`
|
|
51
|
-
| `./filter`
|
|
52
|
-
| `./sync-types`
|
|
53
|
-
| `./realtime-types`
|
|
54
|
-
| `./auth-types`
|
|
55
|
-
| `./storage-types`
|
|
56
|
-
| `./constants`
|
|
57
|
-
| `./schema`
|
|
46
|
+
| Entrypoint | Contents |
|
|
47
|
+
|----------------------------|----------------------------------------------------|
|
|
48
|
+
| `@boltstore/utils` | Barrel (all exports) |
|
|
49
|
+
| `./types` | Record, Collection, User, Application, ApiKey types |
|
|
50
|
+
| `./validation` | Field validators (email, url, required, etc.) |
|
|
51
|
+
| `./filter` | Filter expression parser & SQL compiler |
|
|
52
|
+
| `./sync-types` | Sync protocol types (VersionVector, LamportClock) |
|
|
53
|
+
| `./realtime-types` | Realtime/WebSocket message types |
|
|
54
|
+
| `./auth-types` | JWT, OAuth2, API key types |
|
|
55
|
+
| `./storage-types` | File storage types (FileInfo, S3Config) |
|
|
56
|
+
| `./constants` | Error codes, limits, defaults |
|
|
57
|
+
| `./schema` | JSON Schema exports for cross-language SDKs |
|
|
58
58
|
|
|
59
59
|
## License
|
|
60
60
|
|