# @any-touch/core

> any-touch核心程序, 主要用来兼容Mouse/Touch事件.

Latest version **2.2.0** (published 2022-05-24) · MIT license · 0 weekly downloads

## Install

```sh
npm install @any-touch/core
pnpm add @any-touch/core
yarn add @any-touch/core
bun add @any-touch/core
```

## Health

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

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.2.0 |
| Published | 2022-05-24 |
| First published | 2020-01-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 34.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | any86 |
| Maintainers | russell-ne |
| Keywords | touch, mouse, gesture |

## Links

- npm: https://www.npmjs.com/package/@any-touch/core
- Repository: https://github.com/any86/any-touch
- Homepage: https://github.com/any86/any-touch#readme
- Issues: https://github.com/any86/any-touch/issues
- npm.io page: https://npm.io/package/@any-touch/core

## Dependencies (2)

- [any-event](https://npm.io/package/any-event.md) ^2.2.0
- [@any-touch/shared](https://npm.io/package/@any-touch/shared.md) ^2.2.0

## Recent versions

- 2.2.0 (latest) — 2022-05-24
- 2.0.3-alpha.0 (next) — 2022-01-18
- 2.1.3 — 2022-05-24
- 2.1.2 — 2022-04-28
- 2.1.1 — 2022-04-08
- 2.1.0 — 2022-04-02
- 2.0.3 — 2022-03-30
- 2.0.3-2.0.3-alpha.1.0 — 2022-03-30
- 2.0.2 — 2022-01-06
- 2.0.2-alpha.1 — 2022-01-06
- 2.0.2-alpha.0 — 2022-01-06
- 2.0.1 — 2021-12-29
- 2.0.1-alpha.0 — 2021-12-28
- 2.0.0 — 2021-12-28
- 2.0.0-alpha.4 — 2021-12-02
- … 55 more at https://npm.io/package/@any-touch/core/versions

## README

# @any-touch/core
🤖核心组件, 主要用来把Mouse/Touch输入变成统一的输出, 实现PC/Mobile端的兼容, 提供了"**at:**"开头的兼容事件.

```javascript
import Core from '@any-touch/core';
const at = new Core(el);
// 兼容Mouse/Touch
at.on('at', (ev) => {
    // ev包含位置/时间/事件对象等属性.
});
// start / move / end / cancel
at.on('at:start', onStart);
at.on('at:move', onMove);
at.on('at:end', onEnd);
at.on('at:cancel', onCancel);
```

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