Skip to content

Instantly share code, notes, and snippets.

@PartyLich
Last active August 22, 2019 20:48
Show Gist options
  • Save PartyLich/332a93f7a8d084d7ef8e1ecdadfecd64 to your computer and use it in GitHub Desktop.
Save PartyLich/332a93f7a8d084d7ef8e1ecdadfecd64 to your computer and use it in GitHub Desktop.
Make you stay out all night long
(function MrGreen() {
class Person {
constructor () {
this.feeling = 5;
this._love = null;
}
get love() { return this._love; }
set love(person) {
this._love = person;
}
inLove(person) {
return person === this.love;
}
reallyFeelGood(person) {
this.feeling = (this.inLove(person))
? 11
: this.feeling;
return this.feeling;
}
}
const you = new Person();
const somebody = new Person();
class LoveAndHappiness {
constructor () {
this.love = true;
this.happiness = true;
}
makeDoWrong(you) {}
makeDoRight(you) {}
}
const wait = (time, callback) =>
window.setTimeout(callback, time);
const aMinute = 1000 * 60;
wait(aMinute, () => ({}));
Error('Something');
const someone = (function getOnPhone() {
return {
pronoun: 'she',
talk: () => 'I can make it right, yeah',
};
})();
const currentTime = () =>
(new Date('08-22-2019 03:00')).getHours();
someone.talk();
const happiness = you.reallyFeelGood(somebody);
const isWrong = (you) => (you.inLove(someone)) ? false : true;
// Oh, baby, love and happiness
// Love and happiness
// Love and happiness (love and happiness) oh
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment