We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2158586 commit b7c7197Copy full SHA for b7c7197
2 files changed
reflex/compiler/utils.py
@@ -152,7 +152,9 @@ def compile_state(state: Type[BaseState]) -> dict:
152
console.warn(
153
f"Failed to compile initial state with computed vars, excluding them: {e}"
154
)
155
- initial_state = state(_reflex_internal_init=True).dict(include_computed=False)
+ initial_state = state(_reflex_internal_init=True).dict(
156
+ initial=True, include_computed=False
157
+ )
158
return format.format_state(initial_state)
159
160
reflex/state.py
@@ -1784,7 +1784,7 @@ def dict(
1784
prop_name: self.get_value(getattr(self, prop_name))
1785
for prop_name in self.base_vars
1786
}
1787
- if initial:
+ if initial and include_computed:
1788
computed_vars = {
1789
# Include initial computed vars.
1790
prop_name: (
0 commit comments