reflex/tests/components
Masen Furer 432fcd4a5b
Account for imports of @rx.memo components for frontend package installation (#2863)
* CustomComponent ignores the annotation type in favor of the passed value

Do not require rx.memo wrapped functions to have 100% correct annotations.

* test_custom_component_get_imports: test imports from wrapped custom components

* Account for imports of custom components for frontend installation

Create new ImportVar that only install the package to avoid rendering the
imports in the page that contains the custom component itself.

* Handle Imports that should never be installed

* Fix up double negative logic

* Perf Optimization: use the imports we already calculate during compile

Instead of augmenting _get_imports with a weird, slow, recursive crawl and
dictionary reconstruction, just use the imports that we compile into the
components.js file to install frontend packages needed by the custom
components.

Same effect, but adds essentially zero overhead to the compilation.
2024-03-15 09:59:59 -07:00
..
base RED-1052/rx.State as Base State (#2146) 2023-11-29 09:43:33 -08:00
core Get rx.color working with fstrings (#2562) 2024-02-09 17:06:55 -08:00
datadisplay Top-level namespace tweaks (#2523) 2024-02-05 11:14:02 -08:00
forms Merge remote-tracking branch 'origin/main' into reflex-0.4.0 2024-02-07 13:53:39 -08:00
graphing fix black+ruff (#2750) 2024-02-28 14:51:50 -08:00
layout Fix fstrings being escaped improperly (#2571) 2024-02-13 14:32:44 -08:00
media Use rx.el.img as rx.image (#2558) 2024-02-08 14:44:53 -08:00
typography remove chakra from markdown component_map (#2709) 2024-02-26 19:34:22 -08:00
__init__.py Add basic unit tests (#7) 2022-11-20 14:34:25 -08:00
test_component.py Account for imports of @rx.memo components for frontend package installation (#2863) 2024-03-15 09:59:59 -07:00
test_tag.py fixed issue with hypens (#2450) 2024-01-26 14:14:46 -08:00