* Add path_ops.update_directory_tree:
Copy missing and newer files from src to dest
* add console.timing context
Log debug messages with timing for different processes.
* Update assets tree as app._compile step.
If the assets change between hot reload, then update them before reloading (in
case a CSS file was added or something).
* Add timing for other app._compile events
* Only copy assets if assets exist
* Fix docstring for update_directory_tree
* increase nested type checking for component var types
* handle mapping as dict in type hint
* fix weird cases of using _isinstance instead of isinstance
* test out nested=0
* move union below
* don't use _instance for simple unions
* add a config variable to add extra overlay components
* add integration test
* Apply suggestions from code review
---------
Co-authored-by: Masen Furer <m_github@0x26.net>
* move benchmarks and add some more
* change key and paths
* parametrize tests
* more specific ignore
* rename fixture
* remove previous file
* add tests for _compile_stateful_components
* remove base_state from event types
* pyi that guy
* unpack is new
* woops
* use type alias type to remove ambiguity of where types go
* use same thing with LAMBDA_OR_STATE
* do it for event type
* add the watermark class
* remove shortcut exposing badge publicly for now
* Rename as "sticky" because "watermark" has a negative connotation
* Add config `show_built_with_reflex`
This config option is available for authenticated users on various plan tiers
* py3.11 compatible f-string
* sticky badge inherit from A instead of using on_click/redirect
* fix integration test
* Move export checking logic to reflex CLI
* rx.logo: make it accessible to screen readers
Add role="img" aria_label="Reflex" and title="Reflex".
* Hide the built with reflex badge for localhost
* Revert "fix integration test"
This reverts commit a978684d70.
* experimental: do not show warning for internal imports
Only show experimental feature warnings when accessing the names through the
rx._x namespace.
If reflex internally imports the names via deep imports, then this bypasses the
warning to avoid showing it to users that have no control over how the
framework uses experimental features.
* add help link for show_built_with_reflex option
* pre-commit fixes
---------
Co-authored-by: Masen Furer <m_github@0x26.net>
* improve rx.Field ObjectVar typing for sqlalchemy and dataclasses
* enable parametrized objectvar tests for sqlamodel and dataclass
* improve typing for ObjectVars in ArrayVars
* ruffing
* drop duplicate objectvar import
* remove redundant overload
* allow optional hints in rx.Field annotations to resolve to the correct var type
* disable react strict mode for event loop
* oops
* pyi oui
* separate socket connection from event loop
* prettier state.js
* disable react strict mode
* didn't work sadge
* socket connect/disconnect depends on new isBackendDisabled state
* only start the event loop when the socket is set or we're not stateful
* Always drain the queue unless backend is disabled
---------
Co-authored-by: Masen Furer <m_github@0x26.net>
* WiP
* Save the var from get_var_name
* flatten StateManagerRedis.get_state algorithm
simplify fetching of states and avoid repeatedly fetching the same state
* Get all the states in a single redis round-trip
* update docstrings in StateManagerRedis
* Move computed var dep tracking to separate module
* Fix pre-commit issues
* ComputedVar.add_dependency: explicitly dependency declaration
Allow var dependencies to be added at runtime, for example, when defining a
ComponentState that depends on vars that cannot be known statically.
Fix more pyright issues.
* Fix/ignore more pyright issues from recent merge
* handle cleaning out _potentially_dirty_states on reload
* ignore accessed attributes missing on state class
these might be added dynamically later in which case we recompute the
dependency tracking dicts... if not, they'll blow up anyway at runtime.
* fix playwright tests, which insist on running an asyncio loop
---------
Co-authored-by: Khaleel Al-Adhami <khaleel.aladhami@gmail.com>
* add backend disabled dialog
* pyi that guy
* pyi the other guy
* extend test_connection_banner to also test the cloud banner
* oops, need asyncio _inside_ the app
* Update reflex/components/core/banner.py
Co-authored-by: Masen Furer <m_github@0x26.net>
* use universal cookies
* fix pre-commit
* revert universal cookie 🍪
---------
Co-authored-by: Masen Furer <m_github@0x26.net>
* add codspeed
* add codspeed to dev deps
* poetry.lock: relock deps, no update
* add poetry run
* only compile components
* at least have something
* fix hash
* dang it darglint
* uwu
* test sorting algorithms
* test sort
* sad
* revert that guy
* add test_evaluate
* it's ruff out there
* delete test_sort
---------
Co-authored-by: Masen Furer <m_github@0x26.net>
* Handle python `range` passed to rx.Var.create
Fix the range function to use Math.ceil to handle jagged steps.
Update test cases.
* Set ToVarOperation.__qualname__ for better repr
* add more type annotations through the code
* add typing in reflex/utils
* misc typing
* more typings
* state typing
* keep typing
* typing init and utils
* more typing for components
* fix attempt for 3.9
* need more __future
* more typings
* type event plz
* type model
* type vars/base.py
* enable 'ANN001' for reflex folder (ignore tests and benchmarks)
* fix pyi
* add missing annotations
* use more precise error when ignoring