All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Support for element traversal via the Visitor pattern (#14)
DefaultSirenElementVisitor
for visitors that don't need to visit every type of elementLinkFinder
for searching an entity's linksActionFiller
for populating an action's fieldsCompositeVisitor
for composing multiple visitors
- Support for crawling an API via
crawl
(#15) - Support for validating fields on action submission (#16)
- Default JSON serializer (#27)
- Advanced
submit
usage examples in the JSDocs - Default serializer is available for extension (see
submit
docs)
- Links to source in the docs are no longer generated
0.8.2 - 2023-08-01
- Custom header pairs (
[string, string][]
) are now merged correctly on action submit (#35)
0.8.1 - 2023-05-25
- Usage docs for
resolve
- Re-export for
Href
andisHref
to round out docs
- Re-export
resolve
(#32)
0.8.0 - 2023-05-25
resolve
function for resolving aSubEntity
- Development section in the README
- Project is now built with Node 18
- Contribution guidelines and code of conduct, which now live here
0.7.0 - 2023-04-20
NOTE: This release includes breaking changes from v0.6.0.
- Support for relative URLs (#21)
- For supporting relative URLs (#21),
follow
'sRequestInit
parameter is now nested in an options object Serialization
'scontentType
is now optional- The default serializer no longer requires
checkbox
fields to use thechecked
extension (#22)
- Submitting a
multipart/form-data
action now includes theboundary
parameter (#23)
0.6.2 - 2023-03-15
EmbeddedEntity
'sproperties
now default to an empty object (#19)
0.6.1 - 2023-03-08
- Made
reflect-metadata
a non-dev dependency (#18)
0.6.0 - 2023-03-06
NOTE: This release includes breaking changes from v0.5.0.
SirenClient
has been removed in favor of top-level functions (see below)- Support for Node.js has been removed (for now), primarily for serialization simplification (#17). Including polyfills for
File
andFormData
may resolve this.
0.5.0 - 2022-01-22
- Default serializer for
multipart/form-data
actions (#8)
0.4.0 - 2021-12-05
- Support for custom serializers
- Default serializer for
text/plain
actions
- Upgraded
@siren-js/core
to v0.3.2 - Aligned newline normalization with HTML's algorithm for converting an entry list to a list of name-value pairs, which normalizes newlines in fields'
name
s and values during action submission.
0.3.1 - 2021-06-12
- Using
@web-std/file
in place ofweb-file-polyfill
(fixes #6)
0.3.0 - 2021-06-02
- When creating entries for action submission, fields'
name
andvalue
properties are converted according to the HTML standard.
0.2.1 - 2021-05-19
- When submitting an action, non-
checkbox
and non-radio
fields with novalue
property are submitted with an empty string value, rather than"undefined"
(#3).
0.2.0 - 2021-05-18
- The client class now has a
headers
property for customizing HTTP headers sent in each request. The property can be initialized via the constructor's options object (see the README).
0.1.0 - 2021-05-03
- Client class for communicating with a Siren server
fetch()
method for hitting API entry pointfollow()
method for following links (including embedded links)submit()
method for submitting actions; currently, only actions whosetype
is"application/x-www-form-urlencoded"
are supported.
- Client
Response
wrapper for parsing Siren responses