spry 8.1.0 copy "spry: ^8.1.0" to clipboard
spry: ^8.1.0 copied to clipboard

Next-generation Dart server framework. Build modern servers and deploy them to the runtime you prefer.

8.1.0 #

Migration guide: Not required.

Highlights #

Spry 8.1.0 expands runtime coverage and adds first-class route-level WebSocket handling without changing the filesystem routing model.

This release adds Deno and Netlify targets, exposes public osrv runtime entrypoints for target-aware integrations, upgrades Spry to osrv 0.6.x, and introduces the new event.ws API for WebSocket upgrades inside normal route handlers.

Breaking Changes #

  • None.

What's New #

Runtime targets

  • Added a Deno target and deploy documentation by @medz in #164.
  • Added a Netlify target, example project, and deploy documentation by @medz in #163.

Runtime integration

  • Added public package:spry/osrv.dart runtime entrypoints, including target-specific exports for Dart, Node, Bun, Cloudflare, Deno, Vercel, and Netlify by @medz in #162.
  • Upgraded Spry to osrv 0.6.x as part of the Deno runtime work by @medz in #164.

WebSocket support

  • Added event.ws with runtime support checks, upgrade-request detection, requested protocol access, and upgrade(...) for route-level WebSocket handling by @medz in #165.
  • Added WebSocket documentation covering handshake semantics, session boundaries, and runtime support expectations by @medz in #165.

Migration note #

  • No migration is required for existing applications. To adopt WebSockets, import package:spry/websocket.dart and use event.ws inside a normal route handler.
  • If you integrate directly with osrv, prefer the new public exports under package:spry/osrv.dart and its target-specific entrypoints.

Full Changelog #

8.0.0 #

Migration guide: https://spry.medz.dev/migration

Highlights #

Spry 8.0.0 aligns the framework with the latest upstream HTTP and routing foundations.

This release upgrades Spry to the Fetch-style Request / Response model from ht 0.3.x and osrv 0.4.x, adopts the roux 0.5.x route syntax changes, and expands filesystem routing with more expressive segment patterns.

Breaking Changes #

  • Spry now follows the upstream Fetch-style Request / Response construction model by @medz in #157.
  • Manual string-path remainder matches must now use /** instead of /* when constructing Spry, MiddlewareRoute, or ErrorRoute by @medz in #155.

Request / Response construction

If you construct exported Request / Response values directly, migrate to the new init-object form:

  • Request(uri, method: 'GET') -> Request(uri, RequestInit(method: HttpMethod.get))
  • Response(status: 404, headers: ..., body: ...) -> Response(body, ResponseInit(status: 404, headers: ...))

What's New #

HTTP foundation upgrade

  • Upgraded to ht 0.3.1 and osrv 0.4.x by @medz in #157.
  • Re-exported RequestInit and ResponseInit from package:spry/spry.dart and package:spry/app.dart by @medz in #157.

Routing upgrade

  • Upgraded to roux 0.5.x by @medz in #155.
  • Kept Spry catch-all scopes aligned with the new ** remainder syntax by @medz in #155.
  • Added richer filesystem route syntax for embedded params, regex params, optional params, repeated params, and single-segment wildcards by @medz in #155.

Examples and docs

  • Split examples by target runtime and added a knex_dart example project by @medz in 13fed0d.
  • Refreshed migration docs and release-facing website copy for the v8 release by @medz in #159.
  • Upgraded project dependencies by @medz in #160.

Migration note #

  • Replace manual /* route strings with /** in Spry, MiddlewareRoute, and ErrorRoute, then re-run your route matching tests after upgrading to roux 0.5.x.
  • If you construct exported Request / Response types directly, migrate to the new Fetch-style init objects. For example: Request(uri, method: 'GET') -> Request(uri, RequestInit(method: HttpMethod.get)) Response(status: 404, headers: ..., body: ...) -> Response(body, ResponseInit(status: 404, headers: ...)) Response.text(...) / Response.empty(...) -> Response(..., ResponseInit(...))

Full Changelog #

7.0.0 #

Migration guide: https://spry.medz.dev/migration

What's Changed #

  • BREAKING: replace the imperative app DSL with the v7 file-based runtime model built around routes/, scoped _middleware.dart / _error.dart, and spry.config.dart.
  • feat(cli): add spry serve and spry build workflows for generated runtimes, including watch mode and explicit root support.
  • feat(runtime): add generated targets for Dart VM, Node.js, Bun, Cloudflare Workers, and Vercel.
  • feat(builder): add config loading, route scanning, runtime generation, and public asset syncing for the new build pipeline.
  • docs: rewrite the documentation site for Spry v7, including the new getting started, runtime, deploy, and migration guides.

6.2.0 #

  • feat: support middleware operators (| Pipe middleware, > middleware with handler)
  • feat: support group routing (app.group(...))
  • docs: add group routes docs

6.1.0 #

  • perf(datr, server): pointless waiting
  • perf: avoid creating event id
  • refactor: Remove event.id

6.0.1 #

  • fix: avoid http response status

6.0.0 #

Migration guide: https://spry.medz.dev/migration

What's Changed #

  • refactor: remove group router (The app.group/app.grouped).
  • refactor: rename app.stack to app.middleware.
  • refactor: remove useRequest(), now use event.request.
  • refactor: remove useHeaders(), now use event.headers/event.request.headers.
  • refactor: remove getClientAddress(), now use event.address.
  • refactor: remove useRequestURI(), now use event.url.
  • refactor: remove useParams(), now use event.params.
  • refactor: rename factory Response.text() to Response.fromString().
  • refactor: rename factory Response.json() to Response.fromJson().
  • refactor: remove all adapter, now is cross-platform.
11
likes
0
points
265
downloads

Publisher

verified publishermedz.dev

Weekly Downloads

Next-generation Dart server framework. Build modern servers and deploy them to the runtime you prefer.

Homepage
Repository (GitHub)
View/report issues

Topics

#server #framework #routing #backend #http

Funding

Consider supporting this project:

github.com
opencollective.com

License

unknown (license)

Dependencies

analyzer, block, coal, ht, osrv, path, roux, watcher, web

More

Packages that depend on spry