1.0.8 • Published 1 year ago

@sky0014/logger v1.0.8

Weekly downloads
-
License
-
Repository
github
Last release
1 year ago

logger

A simple logger for js.

Install

npm install @sky0014/logger

Usage

import logger, { createLogger } from "@sky0014/logger";

// default logger, for most common use
logger.initLogger({
  enable: true,
  prefix: "easystore",
});

logger.log("hello there"); // [easystore] hello there

// isolated from default logger, for library use
const anotherLogger = createLogger();

anotherLogger.initLogger({
  enable: true,
  prefix: "another",
});

anotherLogger.log("hello there"); // [another] hello there

Publish

If your first time publish a package, login first:

npm login --registry=https://registry.npmjs.org

Then you can publish:

npm run pub
1.0.8

1 year ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago