BasicTools.md 473 Bytes
Newer Older
涂茜's avatar
涂茜 committed
1 2 3
---
title: BasicTools - 通用工具库
nav:
4
  title: 基础组件
涂茜's avatar
涂茜 committed
5 6 7 8 9 10 11 12 13 14 15 16 17 18
  path: /components
group:
  path: /
---

# BasicTools 通用工具库

## 代码演示

<code src="./demos/Basic.tsx">

## 使用说明

```javascript
19
import { getTimeRange, getRange } from 'packages/base-components/BasicTools/lib/index';
涂茜's avatar
涂茜 committed
20 21 22 23 24 25 26

let result1 = getTimeRange('lastYear');
let result2 = getTimeRange('nextWeek');

let result3 = getRange(new Date(), 'day');
let result4 = getRange('', 'month');
```