
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
A lightweight client-side logger, useful for production.
Typical use case: you don't want to show a mass of console-logs for everyone, who will open browser's console in your web-application. But you want to see these logs by demand. So you can type the code below in console:
FrontLog.setLevel(FrontLog.LEVELS.DEBUG);
and then just refresh the page. The logging level stores in browser's local storage, so you get all your logs after page refresh.
Or you can add logLevel={LEVEL}
to the URL of your page.
For example: /my-supper-app/?logLevel=error
.
Log level from query string has the highest priority, if present.
There are six levels of logs:
var log = FrontLog;
log.trace('This is trace log record');
log.debug('This is debug log record');
log.info('This is info log record');
log.warn('This is warn log record');
log.error('This is error log record');
log.fatal('This is fatal log record');
trace
level is the lowest and fatal
is the highest. Each logging level shows all logs from this level to the highest.
var FrontLog = require('front-log');
or
<script src="dist/front-log.min.js"></script>
See demo/index.html
.
FAQs
A light-weight client-side logger, useful for production.
The npm package front-log receives a total of 3 weekly downloads. As such, front-log popularity was classified as not popular.
We found that front-log demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.