Skip to content

Releases: koajs/koa

v3.1.1

27 Oct 04:27
Immutable release. Only release title and notes can be modified.
v3.1.1
2e52fb5

Choose a tag to compare

What's Changed

  • fix: only original value destroy if the new value is not a stream by @yowainwright in #1914

Full Changelog: v3.1.0...v3.1.1

v3.1.0

26 Oct 13:17
Immutable release. Only release title and notes can be modified.
v3.1.0
1c642f4

Choose a tag to compare

What's Changed

Full Changelog: v3.0.3...v3.1.0

v3.0.3

18 Oct 14:22
Immutable release. Only release title and notes can be modified.
v3.0.3
ffd497a

Choose a tag to compare

What's Changed

Full Changelog: v3.0.2...v3.0.3

v2.16.3

18 Oct 14:36
Immutable release. Only release title and notes can be modified.
v2.16.3
c8af309

Choose a tag to compare

What's Changed

Full Changelog: v2.16.2...v2.16.3

v3.0.2

17 Oct 06:56
v3.0.2
433b20c

Choose a tag to compare

What's Changed

  • fix: fixes response.attachment behaviour leads to Content-Type Sniffing by @yowainwright in #1904
  • chore: use NPM trusted publishing with semver tag triggers by @Copilot in #1907

New Contributors

  • @Copilot made their first contribution in #1907

Full Changelog: v3.0.1...v3.0.2

v2.16.2

30 Jul 00:02
v2.16.2
3b16886

Choose a tag to compare

What's Changed

  • fix: only allow back redirect to the same origin referer by @fengmk2 in #1898

Full Changelog: v2.16.1...v2.16.2

v3.0.1

27 Jul 07:38
v3.0.1
1ddb048

Choose a tag to compare

What's Changed

  • fix(security): only allow same origin referer on response back 422c551
  • chore: adds initial doc text refresh; migration guide [CHORE-1870] by @yowainwright in #1877
  • build(deps-dev): bump formidable from 3.5.2 to 3.5.4 by @dependabot[bot] in #1878
  • chore: removes done callbacks in tests [CHORE-1870] by @yowainwright in #1875
  • build(deps-dev): bump supertest from 7.1.0 to 7.1.1 by @dependabot[bot] in #1879
  • build(deps): bump debug from 4.4.0 to 4.4.1 by @dependabot[bot] in #1880
  • feat: replace debug module with pure node:util::debuglog by @3imed-jaberi in #1885
  • feat: replace cache-content-type with mime-types directly by @3imed-jaberi in #1886
  • build(deps): bump statuses from 2.0.1 to 2.0.2 by @dependabot[bot] in #1888
  • build(deps-dev): bump supertest from 7.1.1 to 7.1.4 by @dependabot[bot] in #1895
  • build(deps-dev): bump form-data from 4.0.3 to 4.0.4 by @dependabot[bot] in #1894

Full Changelog: v3.0.0...v3.0.1

v3.0.0

28 Apr 00:40

Choose a tag to compare

This is a major release.

Breaking

  • Minimum node v18
  • Removes .redirect('back'), adds .back(fallback_url) @fl0w #1115
  • For .redirect(), don't render redirect values in anchor ref ff25eb4
  • req.origin should display the origin header if it exists, not the current hostname #1008. origin now aligns with the Origin header as used in CORS.
  • .body=<json> should not overwrite type if type already json #1120
  • Remove special ENOENT support #1861 - this is a big change and will require any file servers to adapt to this change for handling 404s / files not found
  • Removes generator deprecation messages. Generators are no longer supported. Koa no longer asserts if generators are used.
    Set content-length: 0 if body is explicitly set to null @ognjenjevremovic #1528
    Remove obsolete createAsyncCtxStorageMiddleware #1817
  • ctx.throw now requires a format of ctx.throw(status, error, properties). See: https://www.npmjs.com/package/http-errors

New

  • Support custom streams @KristapsR #1825
  • Support WHATWG response bodies #1830 @kravorkid
  • Use asyncLocalStorage to get current context from app, e.g.: const ctx = app.currentContext.

Fixes

  • Handle responses when socket is no longer writable @titanism @Azlond #1593
  • fix: Do not response Content-Length if Transfer-Encoding is defined #1562 @charlyzeng
  • fix: Set body to 'null' if ctx.type = 'json' and ctx.body = null #1059 @likegun
  • fix: can not get currentContext in error handler (#1758) (Gxkl <[email protected]>)
  • Fix exports.defaults in package.json #1630
  • Fix leaky handles in tests #1838
  • Fix body null checks #1814
  • Fix reformatting redirect URLs #1805 #1804
  • Fix passing ctx in error handler #1758
  • Avoid redos on host and protocol getter

Refactors

Dependencies

  • bump type-is@2
  • bump http-errors@2
  • bump [email protected]
  • bump statuses@2
  • bump supertest@7

3.0.0-alpha.5

06 Apr 21:43

Choose a tag to compare

fix: don't render redirect values in anchor ref

v2.16.1

06 Apr 21:41

Choose a tag to compare

fix: don't render redirect values in anchor ref