Skip to content

Commit

Permalink
Update examples
Browse files Browse the repository at this point in the history
  • Loading branch information
mpfeil committed Nov 19, 2019
1 parent 4584d4d commit 8ca1937
Showing 1 changed file with 9 additions and 22 deletions.
31 changes: 9 additions & 22 deletions example.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,12 @@
const luqs = require('.')

luqs()
.then(response => {
console.log(response)
})
.catch(error => {
console.log(error)
})
const run = async () => {
const stations = await luqs()
console.log(stations)
const unna = await luqs.station('unna')
console.log(unna)
const currentMeasurements = await luqs.aktuell()
console.log(currentMeasurements)
}

luqs.station('unna')
.then(response => {
console.log(response)
})
.catch(error => {
console.log(error)
})

luqs.aktuell()
.then(response => {
console.log(response)
})
.catch(error => {
console.log(error)
})
run()

0 comments on commit 8ca1937

Please sign in to comment.