This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const request = require('request') | |
const host = '' | |
const interval = 100 | |
const president = 'That guy' | |
let voteCount = 0 | |
let errorCount = 0 | |
const handleResult = (err, res, body) => { | |
if (!err && res.statusCode === 200) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const R = require('ramda') | |
const request = require('request') | |
const cheerio = require('cheerio') | |
const host = '' | |
const refreshInterval = 5000 | |
const sortByScore = R.sortWith([R.descend(R.prop('score'))]) | |
function getScores(data) { | |
const $ = cheerio.load(data) | |
let rawScores = $('#results').text().trim().split(' | ') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'Jag talar Rövarspråket!' | |
.split('') | |
.reduce((a, b) => a + ('bcdfghjklmnpqrstvwxz'.split('').includes(b.toLowerCase()) ? b + 'o' + b.toLowerCase() : b), '') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifdef GL_ES | |
precision mediump float; | |
#endif | |
uniform float time; | |
uniform vec2 resolution; | |
#define PI 3.1415926535898 | |
#define EPS 0.01 | |
const float clipFar = 100.0; | |
const float scaler = 1.0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifdef GL_ES | |
precision mediump float; | |
#endif | |
uniform float time; | |
uniform vec2 resolution; | |
#define PI 3.1415926535898 | |
#define EPS 0.01 | |
const float clipFar = 16.0; |