Skip to content

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jan 13, 2025

This PR contains the following updates:

Package Change Age Confidence Type Update
@hono/vite-dev-server ^0.18.0 -> ^0.23.0 age confidence dependencies minor
@hono/zod-validator (source) ^0.4.0 -> ^0.7.0 age confidence dependencies minor
@types/node (source) 22.10.5 -> 22.18.11 age confidence devDependencies minor
dcarbone/install-jq-action v3.0.1 -> v3.2.0 age confidence action minor
hono (source) 4.6.16 -> 4.10.1 age confidence dependencies minor
prettier (source) 3.4.2 -> 3.6.2 age confidence devDependencies minor
python 3.12.1 -> 3.14.0 age confidence uses-with minor
tsx (source) 4.19.2 -> 4.20.6 age confidence devDependencies minor
typescript (source) 5.7.2 -> 5.9.3 age confidence devDependencies minor
vite (source) 6.0.7 -> 6.4.0 age confidence devDependencies minor
vite-plugin-dts 4.4.0 -> 4.5.4 age confidence devDependencies minor
zod (source) 3.24.1 -> 3.25.76 age confidence dependencies minor
zod-to-json-schema 3.24.1 -> 3.24.6 age confidence devDependencies patch
zod-validation-error 3.4.0 -> 3.5.3 age confidence dependencies minor

Release Notes

honojs/vite-plugins (@​hono/vite-dev-server)

v0.23.0

Compare Source

Minor Changes

v0.22.0

Compare Source

Minor Changes

v0.21.1

Compare Source

Patch Changes

v0.21.0

Compare Source

Minor Changes

v0.20.1

Compare Source

Patch Changes

v0.20.0

Compare Source

Minor Changes

v0.19.1

Compare Source

Patch Changes

v0.19.0

Compare Source

Minor Changes

v0.18.3

Compare Source

Patch Changes

v0.18.2

Compare Source

Patch Changes

v0.18.1

Compare Source

Patch Changes
honojs/middleware (@​hono/zod-validator)

v0.7.4

Compare Source

Patch Changes

v0.7.3

Compare Source

Patch Changes

v0.7.2

Compare Source

Patch Changes

v0.7.1

Compare Source

Patch Changes

v0.7.0

Compare Source

Minor Changes

v0.6.0

Compare Source

Minor Changes

v0.5.0

Compare Source

Minor Changes

v0.4.3

Compare Source

Patch Changes
dcarbone/install-jq-action (dcarbone/install-jq-action)

v3.2.0

Compare Source

What's Changed

New Contributors

Full Changelog: dcarbone/install-jq-action@v3.1.1...v3.2.0

v3.1.1

Compare Source

What's Changed

Full Changelog: dcarbone/install-jq-action@v3...v3.1.1

v3.1.0

Compare Source

What's Changed

Full Changelog: dcarbone/install-jq-action@v3...v3.1.0

honojs/hono (hono)

v4.10.1

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.10.0...v4.10.1

v4.10.0

Compare Source

Release Notes

Hono v4.10.0 is now available!

This release brings improved TypeScript support and new utilities.

The main highlight is the enhanced middleware type definitions that solve a long-standing issue with type safety for RPC clients.

Middleware Type Improvements

Imagine the following app:

import { Hono } from 'hono'

const app = new Hono()

const routes = app.get(
  '/',
  (c) => {
    return c.json({ errorMessage: 'Error!' }, 500)
  },
  (c) => {
    return c.json({ message: 'Success!' }, 200)
  }
)

The client with RPC:

import { hc } from 'hono/client'

const client = hc<typeof routes>('/')

const res = await client.index.$get()

if (res.status === 500) {
}

if (res.status === 200) {
}

Previously, it couldn't infer the responses from middleware, so a type error was thrown.

CleanShot 2025-10-17 at 06 51 48@​2x

Now the responses are correctly typed.

CleanShot 2025-10-17 at 06 54 13@​2x

This was a long-standing issue and we were thinking it was super difficult to resolve it. But now come true.

Thank you for the great work @​slawekkolodziej!

cloneRawRequest Utility

The new cloneRawRequest utility allows you to clone the raw Request object after it has been consumed by validators or middleware.

import { cloneRawRequest } from 'hono/request'

app.post('/api', async (c) => {
  const body = await c.req.json()

  // Clone the consumed request
  const clonedRequest = cloneRawRequest(c.req)
  await externalLibrary.process(clonedRequest)
})

Thanks @​kamaal111!

New features

  • feat(types): passing middleware types #​4393
  • feat(ssg): add default plugin that defines the recommended behavior #​4394
  • feat(request): add cloneRawRequest utility for request cloning #​4382

All changes

New Contributors

Full Changelog: honojs/hono@v4.9.12...v4.10.0

v4.9.12

Compare Source

What's Changed

  • refactor: internal structure of PreparedRegExpRouter for optimization and added tests by @​usualoma in #​4456
  • refactor: use protected methods instead of computed properties to allow tree shaking by @​usualoma in #​4458

Full Changelog: honojs/hono@v4.9.11...v4.9.12

v4.9.11

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.9.10...v4.9.11

v4.9.10

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.9.9...v4.9.10

v4.9.9

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.9.8...v4.9.9

v4.9.8

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.9.7...v4.9.8

v4.9.7

Compare Source

Security

  • Fixed an issue in the bodyLimit middleware where the body size limit could be bypassed when both Content-Length and Transfer-Encoding headers were present. If you are using this middleware, please update immediately. Security Advisory

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.9.6...v4.9.7

v4.9.6

Compare Source

Security

Fixed a bug in URL path parsing (getPath) that could cause path confusion under malformed requests.

If you rely on reverse proxies (e.g. Nginx) for ACLs or restrict access to endpoints like /admin, please update immediately.

See advisory for details: GHSA-9hp6-4448-45g2

What's Changed

Full Changelog: honojs/hono@v4.9.5...v4.9.6

v4.9.5

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.9.4...v4.9.5

v4.9.4

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.9.3...v4.9.4

v4.9.3

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.9.2...v4.9.3

v4.9.2

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.9.1...v4.9.2

v4.9.1

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.9.0...v4.9.1

v4.9.0

Compare Source

Release Notes

Hono v4.9.0 is now available!

This release introduces several enhancements and utilities.

The main highlight is the new parseResponse utility that makes it easier to work with RPC client responses.

parseResponse Utility

The new parseResponse utility provides a convenient way to parse responses from Hono RPC clients (hc). It automatically handles different response formats and throws structured errors for failed requests.

import { parseResponse, DetailedError } from 'hono/client'

// result contains the parsed response body (automatically parsed based on Content-Type)
const result = await parseResponse(client.hello.$get()).catch(
  // parseResponse automatically throws an error if response is not ok
  (e: DetailedError) => {
    console.error(e)
  }
)

This makes working with RPC client responses much more straightforward and type-safe.

Thanks @​NamesMT!

New features

  • feat(bun): allow importing upgradeWebSocket and websocket directly #​4242
  • feat(aws-lambda): specify content-type as binary #​4250
  • feat(jwt): add validation for the issuer (iss) claim #​4253
  • feat(jwk): add headerName to JWK middleware #​4279
  • feat(cookie): add generateCookie and generateSignedCookie helpers #​4285
  • feat(serve-static): use join to correct path resolution #​4291
  • feat(jwt): expose utility function verifyWithJwks for external use #​4302
  • feat: add parseResponse util to smartly parse hc's Response #​4314
  • feat(ssg): mark old hook options as deprecated #​4331

All changes

New Contributors

Full Changelog: honojs/hono@v4.8.12...v4.9.0

v4.8.12

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.11...v4.8.12

v4.8.11

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.10...v4.8.11

v4.8.10

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.8.9...v4.8.10

v4.8.9

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.8...v4.8.9

v4.8.8

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.7...v4.8.8

v4.8.7

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.6...v4.8.7

v4.8.6

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.5...v4.8.6

v4.8.5

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.4...v4.8.5

v4.8.4

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.3...v4.8.4

v4.8.3

Compare Source

What's Changed

New Contributors

Full Changelog: honojs/hono@v4.8.2...v4.8.3

v4.8.2

Compare Source

What's Changed

Full Changelog: honojs/hono@v4.8.1...v4.8.2

v4.8.1

Compare Source

What's Changed
New Contributors

Full Changelog: honojs/hono@v4.8.0...v4.8.1

v4.8.0

Compare Source

Release Notes

Hono v4.8.0 is now available!

This release enhances existing features with new options and introduces powerful helpers for routing and static site generation. Additionally, we're introducing new third-party middleware packages.

  • Route Helper
  • JWT Custom Header Location
  • JSX Streaming Nonce Support
  • CORS Dynamic allowedMethods
  • JWK Allow Anonymous Access
  • Cache Status Codes Option
  • Service Worker fire() Function
  • SSG Plugin System

Plus new third-party middleware:

  • MCP Middleware
  • UA Blocker Middleware
  • Zod Validator v4 Support

Let's look at each of these.

Reduced the code size

First, this update reduces the code size! The smallest hono/tiny package has been reduced by about 800 bytes from v4.7.11, bringing it down to approximately 11 KB. When gzipped, it's only 4.5 KB. Very tiny!

Route Helper

New route helper functions provide easy access to route information and path utilities.

import { Hono } from 'hono'
import {
  matchedRoutes,
  routePath,
  baseRoutePath,
  basePath,
} from 'hono/route'

const api = new Hono()

api.get('/users/:id/posts/:postId', (c) => {
  const matched = matchedRoutes(c) // Array of matched route handlers
  const current = routePath(c) // '/api/users/:id/posts/:postId'
  const base = baseRoutePath(c) // '/api' Base route path
  const appBase = basePath(c) // '/api' Base path
  return c.json({ matched, current, base, appBase })
})

const app = new Hono()
app.route('/api', api)

export default app

These helpers make route introspection cleaner and more explicit.

Thanks @​usualoma!

JWT Custom Header Location

JWT middleware now supports custom header locations beyond the standard Authorization header. You can specify any header name to retrieve JWT tokens from.

import { Hono } from 'hono'
import { jwt } from 'hono/jwt'

const app = new Hono()

app.use(
  '/api/*',
  jwt({
    secret: 'secret-key',
    headerName: 'X-Auth-Token', // Custom header name
  })
)

app.get('/api/protected', (c) => {
  return c.json({ message: 'Protected resource' })
})

This is useful when working with APIs that use non-standard authentication headers.

Thanks @​kunalbhagawati!

JSX Streaming Nonce Support

JSX streaming now supports nonce values for Content Security Policy (CSP) compliance. The streaming context can include a nonce that gets applied to inline scripts.

import { Hono } from 'hono'
import {
  renderToReadableStream,
  Suspense,
  StreamingContext,
} from 'hono/jsx/streaming'

const app = new Hono()

app.get('/', (c) => {
  const stream = renderToReadableStream(
    <html>
      <body>
        <StreamingContext
          value={{ scriptNonce: 'random-nonce-value' }}
        >
          <Suspense fallback={<div>Loading...</div>}>
            <AsyncComponent />
          </Suspense>
        </StreamingContext>
      </body>
    </html>
  )

  return c.body(stream, {
    headers: {
      'Content-Type': 'text/html; charset=UTF-8',
      'Transfer-Encoding': 'chunked',
      'Content-Security-Policy':
        "script-src 'nonce-random-nonce-value'",
    },
  })
})

Thanks @​usualoma!

CORS Dynamic allowedMethods

CORS middleware now supports dynamic allowedMethods based on the request origin. You can provide a function that returns different allowed methods depending on the origin.

import { Hono } from 'hono'
import { cors } from 'hono/cors'

const app = new Hono()

app.use(
  '*',
  cors({
    origin: ['https://example.com', 'https://api.example.com'],
    allowMethods: (origin) => {
      if (origin === 'https://api.example.com') {
        return ['GET', 'POST', 'PUT', 'DELETE']
      }
      return ['GET', 'POST'] // Default for other origins
    },
  })
)

This enables fine-grained control over CORS policies per origin.

Thanks @​Kanahiro!

JWK Allow Anonymous Access

JWK middleware now supports anonymous access with the allow_anon option. When enabled, requests without valid tokens can still proceed to your handlers.

import { Hono } from 'hono'
import { jwk } from 'hono/jwk'

const app = new Hono()

app.use(
  '/api/*',
  jwk({
    jwks_uri: 'https://example.com/.well-known/jwks.json',
    allow_anon: true,
  })
)

app.get('/api/data', (c) => {
  const payload = c.get('jwtPayload')
  if (payload) {
    return c.json({ message: 'Authenticated user', user: payload })
  }
  return c.json({ message: 'Anonymous access' })
})

Additionally, keys and jwks_uri options now support functions that receive the context, enabling dynamic key resolution.

Thanks @​Beyondo!

Cache Status Codes Option

Cache middleware now allows you to specify which status codes should be cached using the cacheableStatusCodes option.

import { Hono } from 'hono'
import { cache } from 'hono/cache'

const app = new Hono()

app.use(
  '*',
  cache({
    cacheName: 'my-cache',
    cacheControl: 'max-age=3600',
    cacheableStatusCodes: [200, 404], // Cache both success and not found responses
  })
)

Thanks @​miyamo2!

Service Worker fire() Function

A new fire() functi

Copy link

cloudflare-workers-and-pages bot commented Jan 13, 2025

Deploying sona-api with  Cloudflare Pages  Cloudflare Pages

Latest commit: 9f0598d
Status: ✅  Deploy successful!
Preview URL: https://1aa4bac6.sona-f2s.pages.dev
Branch Preview URL: https://renovate-all-minor-patch.sona-f2s.pages.dev

View logs

@renovate renovate bot force-pushed the renovate/all-minor-patch branch 2 times, most recently from ab6f6b5 to 01ccb97 Compare January 16, 2025 09:35
@renovate renovate bot changed the title chore(deps): update all non-major dependencies fix(deps): update all non-major dependencies Jan 16, 2025
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 8 times, most recently from 01c9879 to 1b36cf9 Compare January 23, 2025 21:28
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 5 times, most recently from 30b2fb1 to 25c90d7 Compare January 31, 2025 20:47
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 4 times, most recently from 0cbf84b to 68bb545 Compare February 9, 2025 14:14
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 8 times, most recently from bd19a6f to 933df28 Compare February 19, 2025 02:05
@renovate renovate bot force-pushed the renovate/all-minor-patch branch from 933df28 to 119d754 Compare February 19, 2025 11:46
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 3 times, most recently from e3e4a85 to 6c711ee Compare September 8, 2025 11:54
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 6 times, most recently from b5e84fa to 577fe63 Compare September 18, 2025 09:14
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 6 times, most recently from af7981b to 5a18f12 Compare October 1, 2025 00:58
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 6 times, most recently from 2948792 to 027c147 Compare October 10, 2025 10:49
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 7 times, most recently from a9f5c56 to 1b5e5e9 Compare October 17, 2025 04:58
@renovate renovate bot force-pushed the renovate/all-minor-patch branch from 1b5e5e9 to 926b4db Compare October 17, 2025 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants