An open API service indexing awesome lists of open source software.

https://github.com/acrool/acrool-js-logger

color style console.log
https://github.com/acrool/acrool-js-logger

console

Last synced: about 1 month ago
JSON representation

color style console.log

Awesome Lists containing this project

README

        

# Acrool JS Logger


Acrool JS Logger Logo


style color console.log

[![NPM](https://img.shields.io/npm/v/@acrool/js-logger.svg?style=for-the-badge)](https://www.npmjs.com/package/@acrool/js-logger)
[![npm](https://img.shields.io/bundlejs/size/@acrool/js-logger?style=for-the-badge)](https://github.com/acrool/js-logger/blob/main/LICENSE)
[![npm](https://img.shields.io/npm/l/@acrool/js-logger?style=for-the-badge)](https://github.com/acrool/acrool-js-logger/blob/main/LICENSE)

[![npm downloads](https://img.shields.io/npm/dm/@acrool/js-logger.svg?style=for-the-badge)](https://www.npmjs.com/package/@acrool/js-logger)
[![npm](https://img.shields.io/npm/dt/@acrool/js-logger.svg?style=for-the-badge)](https://www.npmjs.com/package/@acrool/js-logger)

## Features

- style color version console.log

## Installation

```bash
yarn add @acrool/js-logger
```

## Examples

```ts
import logger from '@acrool/js-logger';

const objectVar = {id: 1, name: 'imaginechiu'};
const arrayVar = [1, 2, 3, 4];
const arrayObjVar = [{id: 1, name: 'imaginechiu'}, {id: 2, name: 'selinwu'}, {id: 3, name: 'garychien'}];

logger.primary('primary', objectVar, arrayVar);
logger.success('success', objectVar, arrayVar);
logger.warning('warning', objectVar, arrayVar);
logger.danger('danger', objectVar, arrayVar);
logger.info('info', objectVar, arrayVar);

```

There is also a example that you can play with it:

[![Play react-editext-example](https://raw.githubusercontent.com/acrool/acrool-js-logger/main/play-in-example-button.svg)](https://acrool-js-logger.pages.dev)

## License

MIT © [Acrool](https://github.com/acrool) & [Imagine](https://github.com/imagine10255)