Skip to content

Releases: Rabbit-Company/Web-JS

v0.18.2

04 Mar 15:49

Choose a tag to compare

Update:

v0.18.1

25 Jan 17:06

Choose a tag to compare

Update:

v0.18.0

24 Jan 20:56

Choose a tag to compare

WebSocket connections now receive real client IP from middleware

Previously, the ipExtract middleware only worked for HTTP requests. WebSocket connections would only see ws.remoteAddress, which shows the direct connection IP (often a proxy or load balancer).
Now, when using ipExtract middleware, the real client IP extracted from headers (e.g., x-forwarded-for, cf-connecting-ip) is automatically passed to WebSocket handlers via ws.data.clientIp.

New WebSocketData Interface

WebSocket handlers now receive typed data with the following properties:

  • clientIp - The real client IP extracted by middleware (like ipExtract)
  • url - The original request URL pathname
  • params - URL parameters extracted from the route (e.g., :roomId)
  • query - Query parameters from the upgrade request

v0.17.0

19 Jan 08:15

Choose a tag to compare

CORS Middleware

  • Fixed invalid Access-Control-Allow-Origin: * when credentials: true
  • Added Vary: Origin when responses reflect the request origin
  • Avoided unnecessary Vary headers when using wildcard (*) origins
  • CORS headers are now only set when an Origin request header is present
  • Improved preflight (OPTIONS) cache correctness
  • Updated tests to match spec-compliant CORS behavior

v0.16.0

01 Nov 11:03

Choose a tag to compare

Added:

  • Websocket support for Bun
  • Expose publish, pendingRequests, pendingWebSockets and subscriberCount on Buns web server

v0.14.0

23 Jun 18:26

Choose a tag to compare

Added:

  • hashAlgorithm, generateETags, shouldGenerateETag, maxETagBodySize and skipETagContentTypes options in cache middleware

v0.13.0

15 Jun 09:20

Choose a tag to compare

Added:

  • Support for Cloudflare Workers

v0.2.0

29 May 06:27

Choose a tag to compare

Added:

  • Dynamic route and middleware removal

v0.1.0

28 May 18:21

Choose a tag to compare

First pre-release