Open ivan-kovatchev opened 2 years ago
The JSON-LD spec uses the following accept header:
Accept: application/ld+json;profile=http://www.w3.org/ns/json-ld#expanded
When I try to use negotiator with this accept header, I'm seeing the following behaviour:
negotiator.mediaType() is application/ld+json negotiator.mediaType(["application/ld+json"]) is undefined
negotiator.mediaType without the parameter is correct, but negotiator.mediaType with the parameter is incorrect.
negotiator.mediaType
This is probably linked to the profile parameter, as adding another MIME type after that works correctly:
profile
Accept: application/ld+json;profile=http://www.w3.org/ns/json-ld#expanded, application/n-quads
negotiator.mediaTypes() is [ 'application/ld+json', 'application/n-quads' ] negotiator.mediaTypes(["application/n-quads"]) is [ 'application/n-quads' ]
Duplicate of #35 , I think.
The JSON-LD spec uses the following accept header:
When I try to use negotiator with this accept header, I'm seeing the following behaviour:
negotiator.mediaType
without the parameter is correct, butnegotiator.mediaType
with the parameter is incorrect.This is probably linked to the
profile
parameter, as adding another MIME type after that works correctly: