addLogEntry function exported ✓ 100.0%
Last updated: 2026-03-01T23:25:47.125Z
Location
Metrics
LOC: 10
Complexity: 2
Params: 1
Coverage: 100.0% (6/6 lines, 1049x executed)
Signature
addLogEntry(entry: LogEntry): : void
Summary
Adds a log entry to the store. Synchronous — queues an async flush to chrome.storage.session.
Source Code
export function addLogEntry(entry: LogEntry): void {
localEntries.push(entry);
if (localEntries.length > maxEntries) {
localEntries = localEntries.slice(-maxEntries);
}
pendingEntries.push(entry);
notifyListeners();
scheduleFlush();
}
Dependencies (Outgoing)
| Target | Type |
|---|---|
| notifyListeners | calls |
| scheduleFlush | calls |
Impact (Incoming)
| Source | Type |
|---|---|
| LogLevel | uses |
| flushBuffer | calls |
| emit | calls |
| logAuditFill | calls |