Added linters and fixed linter warnings
This commit is contained in:
16
example.js
16
example.js
@ -1,11 +1,13 @@
|
||||
const ShiftStats = require('./index')
|
||||
'use strict';
|
||||
|
||||
let s = new ShiftStats()
|
||||
const ShiftStats = require('./index');
|
||||
|
||||
let s = new ShiftStats();
|
||||
// with promises
|
||||
s.login().then(() => {
|
||||
return s.divisionStandings(4702)
|
||||
}).then(async (standings) => {
|
||||
console.log(standings.teams)
|
||||
return s.divisionStandings(4702);
|
||||
}).then(async(standings) => {
|
||||
console.log(standings.teams);
|
||||
// with async/await
|
||||
console.log((await s.gameGoals(166658, 'home')).home_goals)
|
||||
})
|
||||
console.log((await s.gameGoals(166658, 'home')).home_goals);
|
||||
});
|
||||
|
Reference in New Issue
Block a user