# conven

> 基本样式及方法库

Latest version **1.0.5** (published 2019-03-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install conven
pnpm add conven
yarn add conven
bun add conven
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.5 |
| Published | 2019-03-19 |
| First published | 2019-02-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 57 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | lxinr |
| Maintainers | lxinr |

## Links

- npm: https://www.npmjs.com/package/conven
- Repository: https://github.com/lxinr/conven
- Issues: https://github.com/lxinr/conven/issues
- npm.io page: https://npm.io/package/conven

## Recent versions

- 1.0.5 (latest) — 2019-03-19
- 1.0.4 — 2019-02-24
- 1.0.3 — 2019-02-24
- 1.0.2 — 2019-02-22

## README

## Conven

基本样式及组件库

### 安装

```
npm install conven --save
# or with yarn
yarn add conven
```

### 使用示例

```
// 使用样式

@import('conven/index.min.css')

// 文本居中及字体色值设置为#fff
<h4 class="txt-center txt-white"></h4>


// 方法

import { setLItem, getLItem } from 'conven'

setLItem('name', 'Jack')
getLItem('name') // Jack
...
```

### 已实现的方法

- [x] cookie

-  getCookie
-  setCookie

- [x] storage

- getSItem
- setSItem
- removeSItem
- getLItem
- setLItem
- removeLItem
- clearLItem

- [x] number

- randomNum
- randomNumRange
- numSep

> 2019-03-19 更新

- [x] device

- isIOS
- isIOS4
- isAndroid
- isAndroid4_3
- isWeixin
- isAlipay

- [x] date

- isLeapYear 判断是否是闰年
- getDaysOfMonth 获取该月的天数
- date2str 格式化时间转为年月日

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