@atproto/syntax 0.1.1 → 0.1.2

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.
Files changed (3) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/README.md +15 -4
  3. package/package.json +12 -4
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # @atproto/syntax
2
2
 
3
+ ## 0.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`41ee177f`](https://github.com/bluesky-social/atproto/commit/41ee177f5a440490280d17acd8a89bcddaffb23b)]:
8
+ - @atproto/common-web@0.2.1
9
+
3
10
  ## 0.1.1
4
11
 
5
12
  ### Patch Changes
package/README.md CHANGED
@@ -1,9 +1,16 @@
1
- # Syntax
1
+ # @atproto/syntax: validation helpers for identifier strings
2
2
 
3
- Validation logic for AT identifiers - DIDs, Handles, NSIDs, and AT URIs.
3
+ Validation logic for [atproto](https://atproto.com) identifiers - DIDs, Handles, NSIDs, and AT URIs.
4
+
5
+ [![NPM](https://img.shields.io/npm/v/@atproto/crypto)](https://www.npmjs.com/package/@atproto/syntax)
6
+ [![Github CI Status](https://github.com/bluesky-social/atproto/actions/workflows/repo.yaml/badge.svg)](https://github.com/bluesky-social/atproto/actions/workflows/repo.yaml)
4
7
 
5
8
  ## Usage
6
9
 
10
+ ### Handles
11
+
12
+ Syntax specification: <https://atproto.com/specs/handle>
13
+
7
14
  ```typescript
8
15
  import { isValidHandle, ensureValidHandle, isValidDid } from '@atproto/syntax'
9
16
 
@@ -17,7 +24,9 @@ ensureValidDid('did:method:val') // returns void
17
24
  ensureValidDid(':did:method:val') // throws
18
25
  ```
19
26
 
20
- ## NameSpaced IDs (NSID)
27
+ ### NameSpaced IDs (NSID)
28
+
29
+ Syntax specification: <https://atproto.com/specs/nsid>
21
30
 
22
31
  ```typescript
23
32
  import { NSID } from '@atproto/syntax'
@@ -43,7 +52,9 @@ NSID.isValid('example.com/foo') // => false
43
52
  NSID.isValid('foo') // => false
44
53
  ```
45
54
 
46
- ## AT URI
55
+ ### AT URI
56
+
57
+ Syntax specification: <https://atproto.com/specs/at-uri-scheme>
47
58
 
48
59
  ```typescript
49
60
  import { AtUri } from '@atproto/syntax'
package/package.json CHANGED
@@ -1,15 +1,23 @@
1
1
  {
2
2
  "name": "@atproto/syntax",
3
- "version": "0.1.1",
4
- "main": "dist/index.js",
3
+ "version": "0.1.2",
5
4
  "license": "MIT",
5
+ "description": "Validation for atproto identifiers and formats: DID, handle, NSID, AT URI, etc",
6
+ "keywords": [
7
+ "atproto",
8
+ "did",
9
+ "nsid",
10
+ "at-uri"
11
+ ],
12
+ "homepage": "https://atproto.com",
6
13
  "repository": {
7
14
  "type": "git",
8
- "url": "https://github.com/bluesky-social/atproto.git",
15
+ "url": "https://github.com/bluesky-social/atproto",
9
16
  "directory": "packages/syntax"
10
17
  },
18
+ "main": "dist/index.js",
11
19
  "dependencies": {
12
- "@atproto/common-web": "^0.2.0"
20
+ "@atproto/common-web": "^0.2.1"
13
21
  },
14
22
  "browser": {
15
23
  "dns/promises": false