1.2.2 • Published 2 years ago

logs-frontend v1.2.2

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

LogsFast

A simple library for logging messages and saving them to localStorage.

📖 Table of Contents

Available Methods

1. log(params: I.Log): void

Logs a message to the console with date/time and optionally saves it to localStorage.

Parameters:

  • params: Object containing log details.
    • type: Log type (information, error, warning, etc.).
    • message: Message to be logged.
    • save (optional): Boolean to determine if the log should be saved to localStorage or not.

2. saveLogLocalStorage(params: I.Log): void

Saves a log message directly to localStorage.

Parameters:

  • params: Object containing log details.
    • type: Log type.
    • message: Message to be logged.

3. downloadLog(format: I.FormatDownload): void

Allows downloading the logs saved in localStorage in different formats.

Parameters:

  • format: File format for download (text, json, pdf).

Usage

import { logsFast } from "logs-frontend";

// Log an informational message to the console
logsFast.log({
  type: "info",
  message: "This is an informational message.",
  save: true, // Saves the message to localStorage
});

// Download the logs in text format
logsFast.downloadLog("text");
1.2.2

2 years ago

1.2.1

2 years ago

1.2.0

2 years ago

1.1.9

2 years ago

1.1.8

2 years ago

1.1.7

2 years ago

1.1.6

2 years ago

1.1.5

2 years ago

1.1.4

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago