ElemeFE / ElemeFE/element

[Bug Report] function isScroll determinedDirection always true

Open
#21,694 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Vue
Stars
54k
Forks
14.4k
PR merge metrics
No merged PRs in 30d

Description

### Element UI version
2.15.7

### OS/Browsers version
chrome 98.0.4758.80

### Vue version
2.6.14

### Reproduction Link
https://github.com/ElemeFE/element/blob/655d89fe0e0d9c4c7c4ca2541f5cf90437690a76/src/utils/dom.js#L179

### Steps to reproduce
```javascript
// line 179
const determinedDirection = vertical !== null || vertical !== undefined
```

determinedDirection always true

suggestions:

1、use "!=" instead of "!=="

2、Change this condition so that determinedDirection does not always evaluate to "true"

### What is Expected?
determinedDirection can be true or false

### What is actually happening?
determinedDirection always true

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.