I basically want to keep a log of the date and time when something happens. That event can happen either on a content or background script, it doesn't matter, because I can change it if it's easier on one or the other.
If I use console.log, the logs are lost if the browser is closed.
I thought about creating an extra html file in my extension and to write the logs there, but I don't know how to do it.
Any advice? How do I write into that html file from the content or background script? I think I don't know some fundamental stuff that prevents me from doing it, or I may be approaching this in the wrong way...
Thanks in advance.