+++
title = "[TRIAGE] Auth code storage strategy — localStorage persistence vs component-only state?"
priority = 7
status = "todo"
ticket_type = "task"
dependencies = ["c3503b"]
+++
This is a triage decision ticket. It must be resolved before dependent implementation tickets can proceed.
Auth code storage strategy for the UI: should the auth code be stored in localStorage (persisted across sessions) or kept only in component state (lost on page reload)?
1. **Component state only** — auth code is lost on page reload. User must re-enter it each time. Simpler and more secure.
2. **localStorage per quote ID** — store `auth_code_{id}` in localStorage so the user doesn't need to re-enter it for quotes they created. Risk: plaintext in localStorage.
3. **Session storage** — same as localStorage but cleared when the tab closes. Middle ground.
1. Research the options above and choose the best approach for this project.
2. Update the `AuthModal` component (ticket f850c6) with the chosen strategy. If localStorage is chosen, implement a clear-on-delete path.
3. Mark this ticket done with a note on the chosen approach in the body or a comment.
`chore(quotesdb): resolve triage — auth-code-storage-strategy-localstorage-persistence-vs-compo`