# rainzth

> 第一个包,主要提供时间格式与标签格式互相转换,大家多多支持

Latest version **6.6.6** (published 2020-12-04) · ISC license · 0 weekly downloads

## Install

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

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 6.6.6 |
| Published | 2020-12-04 |
| First published | 2020-11-30 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 2.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | rainzth |
| Keywords | Web, Node.js, 时间格式, 标签格式 |

## Links

- npm: https://www.npmjs.com/package/rainzth
- npm.io page: https://npm.io/package/rainzth

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 6.6.6 (latest) — 2020-12-04
- 5.2.1 — 2020-12-04
- 3.0.0 — 2020-12-04
- 1.1.1 — 2020-11-30

## README

## 安装方式
```
npm install rainzth
```
## 导入方式
```js
const rainzth = require('rainzth')
```


## 格式化时间dateChange
```js
//调用dateChange对时间进行格式化
const dt = rainzth.dateChange(new Date())
// 结果  2021-01-01 00:00:01
console.log(dt)
```

## 转义HTML中的特殊字符htmlChange
```js
//给出待转化的字符
const str = '<h1 title="abc">这是h1标签<span>123&nbsp;</span></h1>'
// 转义
const str_change= rainzth.htmlChange(str)
console.log(str_change)
// 转化结果
//&lt;h1 title=&quot;abc&quot;&gt;这是h1标签&lt;span&gt;123&amp;nbsp;&lt;/span&gt;&lt;/h1&gt;
```
## 还原HTML中的特殊字符
```js
const str = rainzth.htmlRecover(str_change)
//此处str_change是上面已转义的,此处拿来借用
console.log(str2)
// 输出的结果 <h1 title="abc">这是h1标签<span>123&nbsp;</span></h1>
```

## 开源协议
ISC

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