reflex/tests
Masen Furer 8477a1aba0
BaseState.get_var_value helper to get a value from a Var (#4553)
* BaseState.get_var_value helper to get a value from a Var

When given a state Var or a LiteralVar, retrieve the actual value associated
with the Var.

For state Vars, the returned value is directly tied to the associated state and
can be modified.

Modifying LiteralVar values or ComputedVar values will have no useful effect.

* Use Var[VAR_TYPE] annotation to take advantage of generics

This requires rx.Field to pass typing where used.

* Add case where get_var_value gets something that's not a var
2025-01-03 15:49:46 -08:00
..
integration enable PTH rule (#4476) 2024-12-13 14:06:26 -08:00
units BaseState.get_var_value helper to get a value from a Var (#4553) 2025-01-03 15:49:46 -08:00
__init__.py upgrade to latest ruff (#3497) 2024-06-19 12:32:13 +02:00
test_node_version.py improve app_src typing (#4324) 2024-11-07 14:08:37 -08:00