Regression Fixes
- re add removed method with better behaviour and tests by @Lendemor in #3986
- hash the state file name by @adhami3310 in #4000
- EventFnArgMismatch fix to support defaults args by @LeoGrosjean in #4004
- serialize default value for disk state manager by @adhami3310 in #4008
- remove format_state and override behavior for bare by @adhami3310 in #3979
- Handle bool cast for optional NumberVar by @masenf in #4010
- use literal var instead of serialize for toast props by @adhami3310 in #4027
New Features
Experimental Dynamic Components
In this release, state vars can be of rx.Component
type and @rx.var
computed vars can return rx.Component
, allowing dynamic component structures to be created on the backend at runtime. This enables the full use of python expressions in generated components, as opposed to rx.cond
and rx.foreach
.
There are performance implications when using dynamic components so prefer static components where possible.
- Component as Var type by @masenf in #3732
- add basic integration test for dynamic components by @adhami3310 in #3990
- use bundled radix ui for dynamic components by @adhami3310 in #3993
- implement _evaluate in state by @adhami3310 in #4018
Run Backend with Granian server
install granian
package and set REFLEX_USE_GRANIAN=1
to run with the new, experimental granian backend (instead of the default uvicorn).
- can run with granian by setting REFLEX_USE_GRANIAN var by @Lendemor in #3919
- change loglevel and fix granian on linux by @adhami3310 in #4012
REFLEX_USE_SYSTEM_NODE
and REFLEX_USE_SYSTEM_BUN
If you prefer to run your own versions of node
and bun
, ensure they are on the PATH
and set these environment variables to 1
.
Improvements
Bump nextjs to 14.2.13
Miscellaneous
- [ENG-3717] [flexgen] Initialize app from refactored code by @masenf in #3918
- Added fill color for progress by @wassafshahzad in #3926
- Use tailwind typography plugin by default by @minimav in #3593
- disable prose by default for rx.html by @adhami3310 in #4001
- use
class_name="prose"
to enable default formatting forrx.html
- allow link as metatags by @Lendemor in #3980
- allow classname to be state vars by @adhami3310 in #3991
- default on_submit in form set to prevent_default by @Lendemor in #4005
Bug Fixes
- [ENG-3824]Make AI template use light mode by @ElijahAhianyo in #3963
- don't camel case keys of dicts in style by @adhami3310 in #3982
- add missing message when running in backend_only by @Lendemor in #4002
- [ENG-3849] Track backend-only vars that are declared without a default value by @masenf in #4016
- improve lifespan typecheck and debug by @Lendemor in #4014
Documentation
- fix: Adding in-line comments for the segmented control: value and on_change by @elviskahoro in #3933
- fix: Adding code comments for segmented control type by @elviskahoro in #3935
Other Changes
- add some unit tests for coverage by @Lendemor in #3947
- always print passed_type by @adhami3310 in #3950
- remove unused badge by @Lendemor in #3955
- add some more tests by @Lendemor in #3965
- use svg elements instead of raw html for logo by @Lendemor in #3978
- bump to 0.6.1 for further dev by @masenf in #3995
- reorganize all tests in a single top folder by @Lendemor in #3981
- Update markdown component map to use new rx.code_block.theme enum by @masenf in #3996
- remove all runtime asserts by @Lendemor in #4019
New Contributors
- @minimav made their first contribution in #3593
- @LeoGrosjean made their first contribution in #4004
Full Changelog: v0.6.0...v0.6.1