# @egjs/conveyer 中文文档

规范地址：https://npmcn.com/package/%40egjs/conveyer/

版本：1\.8\.1-alpha\.0
npm 元数据更新时间：2025-10-24T06:49:46.646Z
中文译文更新时间：2026-11-13T09:08:44.881Z
软件包许可：MIT

本文由上游 README 翻译，可能存在偏差，请结合原文核对 API、命令与配置。版权与许可归原作者所有。

原始 npm 页面：https://www.npmjs.com/package/%40egjs/conveyer
原文对照：https://npmcn.com/package/%40egjs/conveyer/?lang=original
项目主页：https://github.com/naver/egjs-conveyer#readme
源码仓库：https://github.com/naver/egjs-conveyer

## 关键信息（来自 npm 元数据）

- 包体积（解压后）：1.7 MB，37 个文件
- 模块格式：ESM + CJS
- TypeScript 类型：包内自带
- 运行依赖：4 个
- 首次发布：2022-02-21T04:03:25.656Z
- 最新版本发布：2025-09-17T17:56:33.365Z
- 近 30 天下载量：21247（2026-10-13 至 2026-11-11，npm 官方下载统计）
- 已发布版本数：51（近 12 个月 0 个）

## 中文简介

Conveyer在您的原生相册中加入了 Drag 手势 .

## 安装

```sh
npm install @egjs/conveyer
```

也可以使用：`pnpm add @egjs/conveyer`、`yarn add @egjs/conveyer`、`bun add @egjs/conveyer`

## README

# ![Conveyer Logo](https://naver.github.io/egjs-conveyer/img/logo.png)  
[轮机](https://naver.github.io/egjs-conveyer/)

[![version](https://img.shields.io/npm/v/@egjs/conveyer.svg?style=flat-square&color=007acc&label=version&logo=NPM)](https://www.npmjs.com/package/@egjs/conveyer) [![npm weekly downloads](https://img.shields.io/npm/dw/@egjs/conveyer?logo=npm&style=flat-square&color=007acc)](https://www.npmjs.com/package/@egjs/conveyer) [![npm bundle size (scoped)](https://img.shields.io/bundlephobia/minzip/@egjs/conveyer.svg?style=flat-square&label=%F0%9F%92%BE%20gzipped&color=007acc)](https://www.npmjs.com/package/@egjs/conveyer) [![Github actions](https://img.shields.io/github/workflow/status/naver/egjs-conveyer/Run%20tests?style=flat-square)](https://github.com/naver/egjs-conveyer/actions) [![Coveralls github](https://img.shields.io/coveralls/github/naver/egjs-conveyer.svg?style=flat-square&label=%E2%9C%85%20coverage)](https://coveralls.io/github/naver/egjs-conveyer?branch=master&style=flat-square) [![](https://img.shields.io/static/v1?style=flat-square&label=%F0%9F%93%9C%20license&message=MIT&color=08CE5D)](https://github.com/naver/egjs-conveyer/blob/main/LICENSE) ![](https://img.shields.io/static/v1.svg?label=&message=TypeScript&color=294E80&style=flat-square&logo=typescript)

[![Angular](https://img.shields.io/static/v1.svg?label=&message=Angular&style=flat-square&logo=Angular&color=dd0031)](https://github.com/naver/egjs-conveyer/blob/main/packages/ngx-conveyer/README.md) [![React](https://img.shields.io/static/v1.svg?label=&message=React&style=flat-square&logo=React&logoColor=white&color=61dafb)](https://github.com/naver/egjs-conveyer/blob/main/packages/react-conveyer/README.md) [![Vue](https://img.shields.io/static/v1.svg?label=&message=Vue3&style=flat-square&logo=Vue.js&logoColor=white&color=42b883)](https://github.com/naver/egjs-conveyer/blob/main/packages/vue-conveyer/README.md) [![Vue](https://img.shields.io/static/v1.svg?label=&message=Vue2&style=flat-square&logo=Vue.js&logoColor=white&color=42b883)](https://github.com/naver/egjs-conveyer/blob/main/packages/vue2-conveyer/README.md) [![Svelte](https://img.shields.io/static/v1.svg?label=&message=Svelte&style=flat-square&logo=svelte&logoColor=white&color=FF3E00)](https://github.com/naver/egjs-conveyer/blob/main/packages/svelte-conveyer/README.md)

### [演示](https://naver.github.io/egjs-conveyer/) 编号 : [文档](https://naver.github.io/egjs-conveyer/docs/api/Conveyer) 编号 : [![](https://naver.github.io/egjs/img/logo.svg) 其他构成部分](https://naver.github.io/egjs/)

**Conveyer在您的原生相册中加入了 Drag 手势 .**  
📱💻🖥

* * *

## \* 特性

-   您可以通过 Drag 使用类似 原生 Scroll 的行为 .
-   通过增加回放,弹性等放松功能,可以创建出"原生"等平滑滚动动画.
-   支持反应属性,通过自动检测变化而不是事件的属性可以改变状态.
-   您可以使用自定义卷轴事件, 如BeginScroll、FinishScroll、ReachStart、LeaveStart,

## \* 安装

#### 无

```bash
$ npm install --save @egjs/conveyer
```

#### 光盘N

-   https://unpkg.com/@egjs/conveyer/dist/ 互联网档案馆的存檔,存档日期2013-12-21

## QQ 快速启动

#### HTML 语言

```html
<div class="items">
  <div class="item"></div>
  <div class="item"></div>
  <div class="item"></div>
  <div class="item"></div>
</div>
```

#### ES 模块

```ts
import Conveyer from "@egjs/conveyer";

const conveyer = new Conveyer(".items");
```

#### 带CDN

```html
<!-- Packaged with all dependencies -->
<!-- https://naver.github.io/egjs-conveyer/release/latest/dist/conveyer.min.js -->
<script src="https://unpkg.com/@egjs/conveyer/dist/conveyer.min.js"></script>
<script>
const conveyer = new Conveyer(".items");
</script>
```

## 如何使用

#### HTML 语言

```html
<button class="prev">prev</button>
<button class="next">next</button>
<div class="items">
  <div class="item"></div>
  <div class="item"></div>
  <div class="item"></div>
  <div class="item"></div>
</div>
```

#### 联合来文

```js
import Conveyer from "@egjs/conveyer";

// Since events occur during initialization, set `autoInit` to false if you want to register events.
const conveyer = new Conveyer(".items", {
  autoInit: false,
});

const prev = document.querySelector(".prev");
const next = document.querySelector(".next");

prev.addEventListener("click", () => {
  // start to end
  conveyer.scrollIntoView("start", {
    align: "end",
    duration: 500,
    excludeStand: true,
  });
});
next.addEventListener("click", () => {
  // end to start
  conveyer.scrollIntoView("end", {
    align: "start",
    duration: 500,
    excludeStand: true,
  });
});
conveyer.subscribe("isReachStart", value => {
  prev.disabled = value;
});
conveyer.subscribe("isReachEnd", value => {
  next.disabled = value;
});

conveyer.init();
```

## • 软件包

| 软件包 | 版本 | 说明 |
| :-: | :-: | :-: |
| [**@egjs/ngx-conveyer (英语)**](https://github.com/naver/egjs-conveyer/blob/main/packages/ngx-conveyer/README.md) | [![version](https://img.shields.io/npm/v/@egjs/ngx-conveyer.svg?style=flat-square&color=dd0031&label=%F0%9F%94%96)](https://www.npmjs.com/package/@egjs/ngx-conveyer) | ![Angular](https://naver.github.io/egjs-conveyer/img/icons/angular.svg) [角质](https://angular.io/) @egjs/召集人端口 |
| [**@egjs/反应召集人**](https://github.com/naver/egjs-conveyer/blob/main/packages/react-conveyer/README.md) | [![version](https://img.shields.io/npm/v/@egjs/react-conveyer.svg?style=flat-square&color=00d8ff&label=%F0%9F%94%96)](https://www.npmjs.com/package/@egjs/react-conveyer) | ![React](https://naver.github.io/egjs-conveyer/img/icons/react.svg) [反应](https://reactjs.org/) @egjs/召集人端口 |
| [**@egjs/vue-conveyer (英语)**](https://github.com/naver/egjs-conveyer/blob/main/packages/vue-conveyer/README.md) | [![version](https://img.shields.io/npm/v/@egjs/vue-conveyer.svg?style=flat-square&color=42b883&label=%F0%9F%94%96)](https://www.npmjs.com/package/@egjs/vue-conveyer) | ![Vue.js](https://naver.github.io/egjs-conveyer/img/icons/vue.svg) [Vue.js@3 (中文(简体) )](https://vuejs.org/v2/guide/index.html) @egjs/召集人端口 |
| [**@egjs/vue2-召集人**](https://github.com/naver/egjs-conveyer/blob/main/packages/vue2-conveyer/README.md) | [![version](https://img.shields.io/npm/v/@egjs/vue2-conveyer.svg?style=flat-square&color=42b883&label=%F0%9F%94%96)](https://www.npmjs.com/package/@egjs/vue2-conveyer) | ![Vue.js](https://naver.github.io/egjs-conveyer/img/icons/vue.svg) [Vue.js@2 请检查isbn=值 (帮助)](https://v3.vuejs.org/) @egjs/召集人端口 |
| [**@egjs/svelte-conveyer (英语)**](https://github.com/naver/egjs-conveyer/blob/main/packages/svelte-conveyer/README.md) | [![version](https://img.shields.io/npm/v/@egjs/svelte-conveyer.svg?style=flat-square&color=FF3E00&label=%F0%9F%94%96)](https://www.npmjs.com/package/@egjs/svelte-conveyer) | ![Svelte](https://naver.github.io/egjs-conveyer/img/icons/svelte.svg) [丝绒](https://svelte.dev/) @egjs/召集人端口 |

## QQ 支持的浏览器

| ![IE](https://simpleicons.org/icons/internetexplorer.svg) | ![Chrome](https://simpleicons.org/icons/googlechrome.svg) | ![Firefox](https://simpleicons.org/icons/firefoxbrowser.svg) | ![Safari](https://simpleicons.org/icons/safari.svg) | ![iOS](https://simpleicons.org/icons/apple.svg) | ![Android](https://simpleicons.org/icons/android.svg) |
| :-: | :-: | :-: | :-: | :-: | :-: |
| 9+( 带有多填充), 11+ 对角 & Svelte | 最新 | 最新 | 最新 | 7个+ | 4+ (中文(简体) ) |

## 德摩斯语

检查我们 [演示文稿](https://naver.github.io/egjs-conveyer/)。 。 。 .

## 页:1

见 [文档](https://naver.github.io/egjs-conveyer/docs/api/Conveyer) 页 次.

## 捐款

见 [捐款额](https://github.com/naver/egjs-conveyer/blob/main/CONTRIBUTING.md)。 。 。 .

## \* 反馈

请存档 [问题](https://github.com/naver/egjs-conveyer/issues)。 。 。 .

## 许可证

@egjs/conveyer 发布在下面 [麻省理工学院许可证](https://npmcn.com/package/%40egjs/conveyer/LICENSE)。 。 。 .

```
Copyright (c) 2022-present NAVER Corp.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
```

[![](https://naver.github.io/egjs/img/logotype1_black.svg)](https://naver.github.io/egjs/)      [![](https://naver.github.io/OpenSourceGuide/book/assets/naver_logo.png)](https://github.com/naver)

## 常见问题

### @egjs/conveyer 是什么？

Conveyer在您的原生相册中加入了 Drag 手势 \.

### 如何安装 @egjs/conveyer？

在项目目录运行 npm install @egjs/conveyer，或使用 pnpm add / yarn add / bun add。

### @egjs/conveyer 支持 TypeScript 吗？

支持。包内自带 TypeScript 类型声明（package\.json 声明了 types 入口），安装后即可获得类型提示，无需再安装 @types 包。

### @egjs/conveyer 支持 ESM 还是 CommonJS？

同时提供 ES Module 与 CommonJS 入口，import 和 require\(\) 都可以使用，打包工具会自动选择合适的版本。

### @egjs/conveyer 可以商用吗？

@egjs/conveyer 使用 MIT 许可。宽松许可：允许商业使用、修改和再分发，通常只需在分发时保留原版权与许可声明。以上为概括，不构成法律意见，请以许可原文为准。

### @egjs/conveyer 的下载量有多少？

根据 npm 官方下载统计，@egjs/conveyer 在 2026/10/13 – 2026/11/11 这 30 天内被下载 21,247 次，日均约 708 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入，适合横向比较热度，不能直接等同于使用人数。

### @egjs/conveyer 还在维护吗？

最新版本 1\.8\.1-alpha\.0 发布于 2025/09/18（1\.2 年前）；至今共发布 51 个版本，其中过去 12 个月发布了 0 个；首次发布于 2022/02/21。发布频率只是参考信号：功能稳定的工具可能很少需要更新，建议结合源码仓库的 issue 和提交记录判断。

