accepts icon indicating copy to clipboard operation
accepts copied to clipboard

Ability to add additional types

Open btilford opened this issue 5 years ago • 0 comments

It would be nice to add types so that the following would work.

// Accepts: application/hal+json
const accept = accepts(req);

switch(accept.type(['json', 'html'])) {
    case 'json':
       // would match both application/json and application/hal+json
    default:
      // 
}

btilford avatar Oct 04 '19 23:10 btilford