github leptos-rs/leptos v0.9.0-rc1

3 hours ago

This release candidate for 0.9.0. 0.9 should be mostly compatible with most user application code. i.e., the migration path should be to upgrade from 0.8 to 0.9 and, in most cases, not need to make any changes. However, note the following changes

  • All server functions now honor the server's request body-size limit, including multipart form data used for uploading files. If you have a server function that uses multipart data to upload files, you should ensure that you have this set to a reasonable limit for your use case (i.e., Axum defaults to 2 megabytes; if you need to support larger file uploads you will need to configure that). In Axum, for example, that can de done globally with a default body limit layer or with middleware on a server function.
  • lazy feature: Lazy-loading/code-splitting is now gated behind a lazy flag on the leptos crate. This saves binary size for anyone who's not using lazy-loading; if you are, just enable the feature.
  • serde_qs 1.0: we've migrated to the 1.0 series of releases for our default server-function input encoding (form URL data). This should reduce the requirement for #[server(default)] and similar workarounds for empty collections.
  • on:toggle is now typed as a ToggleEvent rather than plain Event
  • Function-call syntax for signal reads is now supported on stable (i.e., let (foo, set_foo) = signal(42); set_foo(13); foo() should work on both stable and nightly)
  • Some of the trait implementations around signals have changed: in the worst case, if you have a component or function that takes impl Fn() -> T and you pass it a Signal<T> you may need to dereference it (foo=*signal rather than foo=signal). Let us know if there are any more noticeable breakages here. There are some awkward tradeoffs with inference and #[prop(into)] and in some cases we've had to make the choice we think will be best for the most use cases. Let me know if there are things that seem obviously wrong or unhelpful.
  • A wide variety of semver-breaking changes that probably won't affect user code.

What's Changed since v0.9.0-rc0

  • fix(server_fn): keep a browser fetch abortable until its body is read by @sabify in #4919
  • chore: also warn when tracing is enabled (see #4949) by @gbj in #4950
  • fix: keep hydrate_lazy async under routes so pending Suspends don… by @adrianncovaci in #4945
  • fix: cancel async polling when the owner is disposed (closes #4948) by @gbj in #4951
  • fix(islands): dispose an island's state when the islands router removes it (closes #4952) by @wdceng in #4953
  • fix(island router): send hydration scripts once by @rpfontana in #4955
  • fix: release lock on current Owner before walking parents when looking up context (closes #4946) by @gbj in #4956
  • fix: dispose boundary child views synchronously by @adrianncovaci in #4960
  • fix: use relative trunk asset paths by @gbj in #4961
  • fix: allow Suspense inside ErrorBoundary (closes #4957) by @gbj in #4958
  • fix: wrap prop names in backticks in generated component docs (closes #4963) by @emilbonnek in #4964
  • fix(reactive_graph): prune dead subscribers and owners created with Owner::new by @kittyandrew in #4966
  • fix: correctly handle rebuilding <Title/> (closes #4968) by @gbj in #4969
  • add timeout to requestIdleCallback in island script by @gbj in #4978
  • fix: don't leave old Owners hanging around for unrelated requests (closes #4967) by @gbj in #4970
  • fix(tachys): only group adjacent keyed moves with the same move_in_dom by @Kanrinin-sama in #4972
  • feat: add {insert, replace}-decoded for ParamsMap by @TERRORW0LF in #4984
  • fix(server_fn): streaming body limits, middleware state and upload errors by @sabify in #4941
  • fix(reactive_stores): patch keyed fields under their own path by @philippedev101 in #4981
  • fix: don't duplicate the nested hydration IDs created by an <ErrorBoundary/> (closes #4980) by @gbj in #4982
  • fix(router): keep the displayed route's data alive until its view is replaced (closes #4971) by @DefectingCat in #4973

New Contributors

Full Changelog: v0.9.0-rc0...v0.9.0-rc1

Don't miss a new leptos release

NewReleases is sending notifications on new releases.