The Form Session represents a browser tab. You can programmatically interact with this via the client.formSession
interface.
This interface contains functions that allows you to:
- get and set attributes
- get the session ID
- invalidate the session
For as long as you navigate between pages and forms using server-side code, attributes in a Form Session are persisted and can be used to pass data between forms without exposing it as a URL parameter, for example.
Invalidating the session removes all form state data (field values etc.) from the Form Session. Once a Form Session has been invalidated interacting with the form results in an error. However, the Form Session itself and any attributes persist.