# subayai-utils

> 一个短小而精悍的现代JavaScript使用工具库

Latest version **1.0.1** (published 2023-02-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install subayai-utils
pnpm add subayai-utils
yarn add subayai-utils
bun add subayai-utils
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2023-02-20 |
| First published | 2023-02-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 130.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | 前端小智 |
| Maintainers | qq449245884 |
| Keywords | vue, JavaScript utils, front end utils, utils, vue utils, react utils |

## Links

- npm: https://www.npmjs.com/package/subayai-utils
- Repository: http://www.longstudy.club/subayai-utils/index.html
- Issues: https://github.com/qq449245884/vue-okr-tree/issues
- npm.io page: https://npm.io/package/subayai-utils

## Dependencies (2)

- [dayjs](https://npm.io/package/dayjs.md) ^1.11.7
- [bignumber.js](https://npm.io/package/bignumber.js.md) ^9.1.1

## Recent versions

- 1.0.1 (latest) — 2023-02-20
- 1.0.0 — 2023-02-16

## README

# 快速上手

## 安装

### 通过 npm 安装

```ts
# npm
npm install subayai-utils

# yarn
yarn add subayai-utils

# pnpm 🔥
pnpm add subayai-utils
```

### 通过 CDN 安装

使用 subayai-utils 最简单的方法是直接在 HTML 文件中引入 CDN 链接，之后你可以通过全局变量 `syTool` 访问到所有方法。

```ts
<script type="module" src="https://cdn.jsdelivr.net/gh/husky-dot/subayai-utils/dist/index.umd.js"></script>

<script>
  const { getCamelCase } = syTool;
  console.log(getCamelCase("a-bc"));
</script>
```

## 引入方式

### ES MODULE 方式

下面是使用 ES MODULE 方式引入 `randomString` 方法，用来生成随机字符串

```ts
import { randomString } from 'subayai-utils';

randomString(20); // ax2fwsKwt3xhXXxHzkpE
```

### CommonJs 方式

下面是使用 ommonJs 方式引入 `randomString` 方法，用来生成随机字符串

```ts
const { randomString } = require('subayai-utils');

randomString(20); // ax2fwsKwt3xhXXxHzkpE
```

或者

```ts
const tquTool = require('subayai-utils');

tquTool.randomString(20); // ax2fwsKwt3xhXXxHzkpE
```

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