Options
All
  • Public
  • Public/Protected
  • All
Menu

Class default

The super component for the entire application. Handles passing state to all components, such as user login/logout. Also handles setting up the router for routing to different links depending on the current URL.

Hierarchy

Index

Constructors

Methods

Constructors

constructor

  • Call super constructor and set initial state such that there is no user. Bind methods.

    Parameters

    • props: IAppProps

      Default props passed in by React.

    Returns default

Methods

login

  • login(user: IUser): void
  • Logs in a user by setting the overall state of the app.

    Parameters

    • user: IUser

      the user to be logged in.

    Returns void

logout

  • logout(): void
  • Logs a user out by changing the state of the app.

    Returns void

render

  • render(): any
  • Handles rendering which page depending on the URL. Also renders the Navbar. Handles state by passing in information about the user to all components.

    Returns any

Generated using TypeDoc