包详细信息

easy-logger-dev

ericluciano27MIT1.0.12

A simple and lightweight JavaScript logging library that allows you to control the visibility of console logs dynamically via localStorage.

logger, logging, easy-logger

自述文件

Easy Logger

An easy to use logger controlled by localStorage.

Install

npm install easy-logger-dev

Download Extension

The download of the extension is important for the functionality of the npm package, as it creates the js_easylogger entry in the localStorage for each opened tab.

📦 Easy Logger
📂 Configs

How to use?

Important: App name should contain only letters and underscores.

Typescript

import { setLogName, log, info, warn, error } from 'easy-logger-dev'

setLogName('app_testing')
log('log')
info('info')
warn('warn')
error('error')

Javascript

<script src="https://cdn.jsdelivr.net/npm/easy-logger-dev@1.0.12/dist/easy-logger-dev.js"></script>
<script>
  EasyLogger.setLogName('app_testing')
  // Install Extension before
  EasyLogger.log('log');
  EasyLogger.info('info');
  EasyLogger.warn('warn');
  EasyLogger.error('error');
</script>