JavaScript logging system