app_wrap.py 531 B

123456789101112131415161718
  1. """Top-level component that wraps the entire app."""
  2. from reflex.components.base.fragment import Fragment
  3. from reflex.components.component import Component
  4. from reflex.ivars.base import ImmutableVar
  5. class AppWrap(Fragment):
  6. """Top-level component that wraps the entire app."""
  7. @classmethod
  8. def create(cls) -> Component:
  9. """Create a new AppWrap component.
  10. Returns:
  11. A new AppWrap component containing {children}.
  12. """
  13. return super().create(ImmutableVar.create("children"))