# @baiwusanyu/utils-log

> ## Type

Latest version **1.1.2** (published 2024-12-12) · MIT license · 0 weekly downloads

## Install

```sh
npm install @baiwusanyu/utils-log
pnpm add @baiwusanyu/utils-log
yarn add @baiwusanyu/utils-log
bun add @baiwusanyu/utils-log
```

## Health

**Score 35/100 (D)** — status: maintenance-mode.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.2 |
| Published | 2024-12-12 |
| First published | 2023-05-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 25.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3 |
| Author | baiwusanyu-c |
| Maintainers | baiwusanyu |
| Keywords | typescript, javascript, utils, vue, vue3, vite, react |

## Links

- npm: https://www.npmjs.com/package/@baiwusanyu/utils-log
- Repository: https://github.com/baiwusanyu-c/bwsy-utils
- Homepage: https://github.com/baiwusanyu-c
- Issues: https://github.com/baiwusanyu-c/bwsy-utils/issues
- npm.io page: https://npm.io/package/@baiwusanyu/utils-log

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.1.2 (latest) — 2024-12-12
- 1.1.1 — 2024-12-12
- 1.1.0 — 2024-12-12
- 1.0.18 — 2023-12-28
- 1.0.17 — 2023-12-28
- 1.0.16 — 2023-09-02
- 1.0.15 — 2023-08-15
- 1.0.14 — 2023-07-08
- 1.0.13 — 2023-05-25
- 1.0.12 — 2023-05-10
- 1.0.11 — 2023-05-08
- 1.0.10 — 2023-05-08
- 1.0.9 — 2023-05-07
- 1.0.8 — 2023-05-04
- 1.0.5 — 2023-05-03
- … 17 more at https://npm.io/package/@baiwusanyu/utils-log/versions

## README

# @baiwusanyu/utils-log

## Type

### TLog

打印输出的情感类型

```typescript
declare type TLog = 'error' | 'warning' | 'info' | 'success'
```

## Function

### log

打印函数，用于情感类型打印，支持`node`和浏览器运行

| 参数       | 参数类型     | 默认值     | 说明 |
|----------|----------|---------|-----------|
| type     | `TLog`   | `-`     | 情感类型 |
| msg      | `String` | `-`     | 文本内容 |
| prefix   | `String` | `globalPrefix` | 自定义前缀 |

### setGlobalPrefix

设置全局的打印前缀

| 参数       | 参数类型     | 默认值 | 说明        |
|----------|----------|-----|-----------|
| prefix   | `String` | `-` | 自定义全局打印前缀 |

---
_Source: https://npm.io/package/@baiwusanyu/utils-log · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
