-
Notifications
You must be signed in to change notification settings - Fork 33
Open
Description
It would be nice if the content negotiation in Strata provided a way to get an ordered list of the media types a client accepts based on q values in the Accept header. For an example of a module that does this, see https://github.com/federomero/negotiator.
In this Accept header value ...
'text/json; q=0.1, text/plain; q=0.2, text/xml; q=0.3, text/html'
I would expect to get back
['text/html', 'text/xml', 'text/plain', 'text/json']
Media types with no q value, such as text/html in this example, default to 1.
Then they are sorted in descending order.
Metadata
Metadata
Assignees
Labels
No labels