Skip to content

Commit 7d65b9a

Browse files
committed
Merge pull request #446 from sij411/fix/426
Add TypeScript support for RFC 6570 URI Template expressions (e.g., {+identifier})
2 parents cbc8aca + 23de239 commit 7d65b9a

7 files changed

Lines changed: 512 additions & 204 deletions

File tree

CHANGES.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,25 @@ To be released.
5050
interoperability with ActivityPub servers that emit relative URLs in
5151
properties like `icon.url` and `image.url`. [[#411], [#443] by Jiwon Kwon]
5252

53+
- Added TypeScript support for all [RFC 6570] URI Template expression types
54+
in dispatcher path parameters. Previously, only simple string expansion
55+
(`{identifier}`) was supported in TypeScript types, while the runtime
56+
already supported all RFC 6570 expressions. Now TypeScript accepts all
57+
expression types including `{+identifier}` (reserved string expansion,
58+
recommended for URI identifiers), `{#identifier}` (fragment expansion),
59+
`{.identifier}` (label expansion), `{/identifier}` (path segments),
60+
`{;identifier}` (path-style parameters), `{?identifier}` (query component),
61+
and `{&identifier}` (query continuation). [[#426], [#446] by Jiwon Kwon]
62+
63+
- Added `Rfc6570Expression<TParam>` type helper.
64+
- Updated all dispatcher path type parameters to accept RFC 6570
65+
expressions: `setActorDispatcher()`, `setObjectDispatcher()`,
66+
`setInboxDispatcher()`, `setOutboxDispatcher()`,
67+
`setFollowingDispatcher()`, `setFollowersDispatcher()`,
68+
`setLikedDispatcher()`, `setFeaturedDispatcher()`,
69+
`setFeaturedTagsDispatcher()`, `setInboxListeners()`,
70+
`setCollectionDispatcher()`, and `setOrderedCollectionDispatcher()`.
71+
5372
- Added inverse properties for collections to Vocabulary API.
5473
[[FEP-5711], [#373], [#381] by Jiwon Kwon]
5574

@@ -108,6 +127,7 @@ To be released.
108127

109128
[FEP-fe34]: https://w3id.org/fep/fe34
110129
[FEP-5711]: https://w3id.org/fep/5711
130+
[RFC 6570]: https://tools.ietf.org/html/rfc6570
111131
[OStatus 1.0 Draft 2]: https://www.w3.org/community/ostatus/wiki/images/9/93/OStatus_1.0_Draft_2.pdf
112132
[RFC 7033 Section 4.4.4.3]: https://datatracker.ietf.org/doc/html/rfc7033#section-4.4.4.3
113133
[#119]: https://github.com/fedify-dev/fedify/issues/119
@@ -120,11 +140,13 @@ To be released.
120140
[#404]: https://github.com/fedify-dev/fedify/pull/404
121141
[#407]: https://github.com/fedify-dev/fedify/pull/407
122142
[#411]: https://github.com/fedify-dev/fedify/issues/411
143+
[#426]: https://github.com/fedify-dev/fedify/issues/426
123144
[#429]: https://github.com/fedify-dev/fedify/issues/429
124145
[#431]: https://github.com/fedify-dev/fedify/pull/431
125146
[#440]: https://github.com/fedify-dev/fedify/issues/440
126147
[#441]: https://github.com/fedify-dev/fedify/issues/441
127148
[#443]: https://github.com/fedify-dev/fedify/pull/443
149+
[#446]: https://github.com/fedify-dev/fedify/pull/446
128150

129151
### @fedify/cli
130152

0 commit comments

Comments
 (0)