Lager - v5.2.0
    Preparing search index...
    • Function

      Handles new user registration.

      This function sends an asynchronous request to the server's registration endpoint with the user's email and password. If the registration is successful, it returns the server's response, which typically includes a success message. Throws an error if the registration fails for any reason, such as server errors or validation issues.

      register

      Parameters

      • email: string

        The email address for the new account.

      • password: string

        The password for the new account.

      Returns Promise<void | AuthResponse>

      A promise that resolves to the server's response upon successful registration, or void if an error occurs.

      If there is an error during the request, it is caught and logged.