github lukeed/worktop v0.4.2

latest releases: v0.8.0-next.18, v0.8.0-next.16, v0.8.0-next.17...
3 years ago

Features

  • (utils): Add viaHEX helper: 34e65a2
    Decodes a hexadecimal string into a Uint8Array
    Note: This is the inverse of the existing toHEX helper.

Patches

  • (cache): Clone Response before Set-Cookie guard: ac19ee9

    This fixes a bug with worktop that only occurred when a handler returned a fetch() call directly and the subrequest was to a resource that was cacheable & had a "Set-Cookie" header.

    In code, this may have looked like:

    API.add('GET', '/example', (req, res) => {
    	return fetch('https://other.com/foobar');
    });

    And where the response from 'https://other.com/foobar' was both cacheable and had a "Set-Cookie" header.

    Any/All other cache usage was (and remains) unaffected.

Don't miss a new worktop release

NewReleases is sending notifications on new releases.