Skip to content

v1.4.0

Compare
Choose a tag to compare
@pi0 pi0 released this 20 Sep 18:27
· 7 commits to main since this release

compare changes

Important

In the interceptors, the ctx.options.headers is now always normalized to Headers.
This is not a breaking change as ofetch >=1.4 will narrow 3 possibilities of HeadersInit to be always normalized Headers.
If you were previously not handling the Headers case and implicitly depending on input, you need to update the logic.

🚀 Enhancements

  • Support retryDelay with callback function (#372)
  • Add better message and code for timeout error (#351)
  • Allow custom global options for $fetch.create (#401)
  • Support interceptors arrays (#353)
  • Always clone and normalize options.headers and options.query (#436)

🩹 Fixes

  • Export types from node export condition (#407)
  • Use the wrapper to allow patching global fetch (#377)

📖 Documentation

  • Add docs for using undici dispatcher (#389)

🌊 Types

  • Add agent and dispatcher options (node-specific) (#308)

✅ Tests

  • Add additional tests for hook errors (7ff4d11)

❤️ Contributors