Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix lint issues #676

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"extends": "standard",
"parserOptions": {
"ecmaVersion": 6,
"ecmaVersion": 2021,
"sourceType": "module"
},
"env": {
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ dist/
.idea
.vscode
.DS_Store
.sass-cache/
7 changes: 3 additions & 4 deletions src/components/autoplay.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export default function (Glide, Components, Events) {
* @return {Void}
*/
mount () {
this.enable();
this.enable()
this.start()

if (Glide.settings.hoverpause) {
Expand Down Expand Up @@ -150,7 +150,7 @@ export default function (Glide, Components, Events) {
})

Events.on(['pause', 'destroy'], () => {
Autoplay.disable();
Autoplay.disable()
Autoplay.stop()
})

Expand All @@ -164,15 +164,14 @@ export default function (Glide, Components, Events) {
Autoplay.start()
})


/**
* Start autoplaying:
* - after each run, to restart autoplaying
* - on playing via API
* - while ending a swipe
*/
Events.on(['play'], () => {
Autoplay.enable();
Autoplay.enable()
Autoplay.start()
})

Expand Down
4 changes: 2 additions & 2 deletions src/components/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ export default function (Glide, Components, Events) {
// While direction is `=` we want jump to
// a specified index described in steps.
if (direction === '=') {
// Check if bound is true,
// Check if bound is true,
// as we want to avoid whitespaces.
if( Glide.settings.bound && toInt(steps) > length ) {
if (Glide.settings.bound && toInt(steps) > length) {
Glide.index = length
return
}
Expand Down
2 changes: 1 addition & 1 deletion tests/functional/carousel.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ describe('Glide initialized as `carousel`', () => {
let glide = new Glide('#glide', {
type: 'carousel',
perView: 2,
cloningRatio: 2,
cloningRatio: 2
})

glide.on('build.after', () => {
Expand Down