From 9f37f2134732c4869f07f5a9d550962e548b41d9 Mon Sep 17 00:00:00 2001 From: TANG <40519806@qq.com> Date: Sat, 20 Apr 2019 16:14:24 +0800 Subject: [PATCH] Update version --- package.json | 7 +++---- src/index.js | 4 ++-- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index a60cf0d..b1edd85 100644 --- a/package.json +++ b/package.json @@ -1,11 +1,10 @@ { "name": "vue-virtual-scroll-list", - "version": "1.3.4", + "version": "1.3.5", "description": "A vue component support big amount data list with high scroll performance.", - "main": "/dist/index.js", + "main": "./src/index.js", "files": [ - "/scr/index.js", - "/dist/index.js" + "./src/index.js" ], "scripts": { "test": "rm -rf coverage && jest", diff --git a/src/index.js b/src/index.js index 8af4da2..199c166 100644 --- a/src/index.js +++ b/src/index.js @@ -274,8 +274,8 @@ index = parseInt(index, 10) index = Math.max(0, index) - var lastStart = delta.total - delta.keeps - var isLast = (index <= delta.total && index >= lastStart) || (index > delta.total) + const lastStart = delta.total - delta.keeps + const isLast = (index <= delta.total && index >= lastStart) || (index > delta.total) if (isLast) { end = delta.total - 1 start = Math.max(0, lastStart)