Overview
While unlikely, a malicious actor or buggy UI could trigger many rapid exports, exhausting browser memory. Add a basic client-side rate limit on export operations.
Proposed Solution
Track time of last export and prevent starting a new one within 2 seconds:
const lastExportRef = useRef<number>(0)
const handleExport = () => {
if (Date.now() - lastExportRef.current < 2000) return
lastExportRef.current = Date.now()
// proceed with export
}
Acceptance Criteria
Overview
While unlikely, a malicious actor or buggy UI could trigger many rapid exports, exhausting browser memory. Add a basic client-side rate limit on export operations.
Proposed Solution
Track time of last export and prevent starting a new one within 2 seconds:
Acceptance Criteria