« first day (2085 days earlier)      last day (2868 days later) » 

3:00 PM
you don't have any private internals
you're exporting everything, so the pattern does nothing but take closure over to identically named variables (which is a Bad Thing)
also, ID: this.Enums.Pending from inside the same object is not going to work
 
we know
that's why came here for help
 
Is this just a case where you're on the client and your trying to "fix" the situation where a user includes your code twice? or what
 
@Pilouk have you looked into how enums are typically done in JS?
 
there seem to be multiple way to do it
 
there are a bunch of ways to do some sort of dumb dictionary, yes
there are only a couple very similar options for actual enums with traditional semantics
11
Q: ES6 read-only enums that can map value to name

ssubeI would like to define an enum-like structure in JS, but have two requirements: The values be read-only, i.e. no users can assign to them. The values (0, 1, 2, ...) can be mapped back into the names (as with Java's name method) The methods I know to create enums like this typically meet one r...

 
3:09 PM
i need both
dictionary just a way to tell i have a key and a value
this is not dumb
 
a dictionary is not an enum
 
i know
It's just a way to access both of them because my tools need both
my dicitonary is base on an enum
 
can someone invite me for dribble?
 
so i can have the control on the description
using n18i
 
i18n?
 
3:12 PM
n8i1?
 
n8!n\9
 
@FastSnail show me your work and I'll decide if thy is worthy ;)
 
you realize that your code is going to make EasySolution.Enums.RequestStatus.Enums?
 
nah this i will not work
 
@towc my websites and portfolio is enough?
 
3:13 PM
i put enum in a var like Luggage told
 
@FastSnail link?
 
just start by flattening everything out
 
@towc thanks you i will send later.i have to finish my works.
@ssube flattening ?
 
@Pilouk this is more better: jsfiddle.net/bf5f0jzf
your use of this wasn't right, even when the object was split out
 
@FlorianMargaine Did you ever get around to this? :P
 
3:20 PM
@SomeGuy didn't go very far
 
Why did "Feeds" post a link to a 2 year old SO question
 
@SomeGuy also, one-year-old message? really?
 
oh, that was from 2years ago
 
@FlorianMargaine Badger Girl's teaching me the art of being creepy. shrug
 
but BadgerCat isn't creepy, so that doesn't check out
 
3:22 PM
@SomeGuy uh, you've got a long way to go then, good luck
 
Don't you talk about our BadgerCat like that.
 
@Trasiva right, she's definitely creepy. Saying otherwise is an insult.
 
@FlorianMargaine Hahaha. I was looking for this message of mine. Came across yours
 
@FlorianMargaine She's the master, not some pleb though.
 
badgercat is too smol to be creepy
 
3:24 PM
@ssube gremlins would like to disagree
 
Badger is like our room mother. She keeps track of us, loves us, and isn't afraid to murder
 
I don't recall my mother ever murdering me.
 
@ssube My mom killed me a few times.
 
-1
Q: Does 'The Book of Programming by Master Yuan-ma' really exist?

Mohit BhardwajI have been reading the 'Eloquent JavaScript' book for last few days. There have been nice quotations from a book mentioned as The Book of Programming. I got interested and tried to find more about this book but there does not seem to be any useful reference to it. Does this book really exist? If...

 
Trasiva's mom killed me a couple times too
wtf is wrong with your mom ssube
 
3:32 PM
@SterlingArcher let me fax you the list. Do you have 5000 sheets of paper ready?
 
yes
wait
no
what is paper
 
not sure tbh
 
Badger sent me her hitlist
I'm very scared now
 
@SterlingArcher oh dude, I got a new box mod last night
 
3:34 PM
Oh word?
 
@ndugger^
 
got sick of the battery life on the one I had
one a them rx200
 
lol yeah I love the battery life on mine
 
@Abhishrek That's a weird instrument
 
it can actually power the 0.15 coil now, which is great
 
3:39 PM
There was talk of a lodash alternative in here.. I can't think of the name
 
@Luggage Array.prototype
 
tbh I really like the .5 coil the best
I don't know why
 
I like a .50 with fruity stuff and a .15 with cream flavors
 
heh.. yea.. i am using much more o fthe array prototype methods now, but there was another library out there that looked useful
 
@Luggage Underscore, ramda, immutable, seamless-immutable?
 
3:42 PM
@Luggage there's a bunch of functional+immutable libraries
ramda and immutablejs are big ones
 
Immutable is by far the best
 
ramda sounds familiar.. that might be what i am thinking of
 
@Luggage underscore?
 
The new array methods make a lot of libs moot these days
 
ramda is some scala derp's overcomplicated dumbness
immutable is super useful tho
 
3:43 PM
^^^
 
@ndugger Arrays make themselves moot
 
Your mum makes me moot
 
@ndugger i agree.. this is for a friend.
I use lodash less and less in favor of Array.prototype
but this jerk is crying he has to write code
 
punch him right in the beer
 
You should introduce him to Scratch
 
3:45 PM
Can this be simplified at-all?
if(document.getElementById("username").value == "") {
   document.getElementById("username").style.border = "1px solid red";
}
 
@Meredith does it have a turtle?
 
heh
 
@TheCodesee if you're repeating the same thing, yes
 
@TheCodesee yes
 
@TheCodesee yes
 
3:46 PM
Could I just do style.border = "1px solid red";
 
@TheCodesee no
 
No
 
ok so.... how could i simplify it?
 
Variable
 
3:47 PM
Cache the DOM object
single line if statement? Falsy check?
let user = document.getElementById("username");
if (!user.value) user.style.border = "1px solid red";
 
Don't do that to your poor if statements
Let them breathe
 
Use a constant variable
 
curly your shit brah
 
I mean
 
No way
Job security brah
 
3:49 PM
shitty style guide brow
 
Also apply a class instead of individual styles
 
const user = document.getElementById('username');
if (!user.value) {
  user.style.border = '1px solid red';
}
 
` . `
fail
 
thanks @ssube
what does the const do?
 
3:50 PM
btw, how does it make sense for dom elements to be constants?
 
@TheCodesee google knows ;)
 
Skipping the curlies is tempting fate. Always make sure there's some space between the curlies before you touch anything.
 
@towc how doesn't it?
 
@towc const is not C++'s const, it's final
 
@littlepootis because they're being mutated all the time?
 
3:50 PM
@towc Preserves the reference
 
23 secs ago, by ssube
@towc const is not C++'s const, it's final
 
oh wow, I'm actually that ignorant, thanks
 
So that you know that mutate(user) mutates the user element, not another element
 
You're not re-assigning when you mutate an object assisned to a const value
 
3:51 PM
109
Q: Java's final vs. C++'s const

WinWinThe Java for C++ programmers tutorial says that (highlight is my own): The keyword final is roughly equivalent to const in C++ What does "roughly" mean in this context? Aren't they exactly the same? What are the differences, if any?

 
Valve knows how to count to 3
 
C++ has deep constancy, preventing the instance from being mutated
Java and JavaScript only use reference constancy, preventing you from assigning to the variable
 
Btw I think you're supposed to check user.value.length === 0
vs !user.value
or user.value == ""
 
those are mostly equivalent
 
@ssube really?
 
3:53 PM
@Meredith duuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuu wut r u duin
 
=== "" and .length === 0 are equivalent
 
so if you pass a const object, object can't be mutated in any way?
 
@FlorianMargaine when you declare a reference/variable const, you can only call const methods, and const methods are not allowed to mutate the object (assign to this.*)
 
@ssube They have the same result
 
nor any of its properties?
 
3:54 PM
@FlorianMargaine it can be mutated, but the variable can't change reference to another object
 
!!afk half day home time
 
@FlorianMargaine well, memory access can always do tricky things
 
have a good freedom weekend y'all
 
but within the language itself, no, it can't be mutated
 
@ssube oh, didn't know about const methods
 
3:54 PM
@towc not with c++ const
from that answer
class Foo {
public:
   void bar();
   void foo() const;
};

void test(const Foo& i) {
   i.foo(); //fine
   i.bar(); //error
}
the compiler just won't let you call a non-const method from a const reference
 
@ssube nice
 
wasn't disagreeing with that :P
 
I think maybe I've talked him out of using some shitty SQL -> JS object abstraction in favor of lodash.
still working on array.prototype
 
Using a list library is still a good idea
 
@SterlingArcher const, you pleb
 
4:00 PM
You still need zip/partition/flatten
 
what does zip do?
 
yea. I think lodash is still nice.
 
@ndugger zips two collections together
 
like concat?
oh wait, no, nevermind
I unerstand
 
It's a super useful function
 
4:02 PM
[1, 2], ['a', 'b'] -> [[1, 'a'], [2, 'b']]?
 
Yeah
 
meh
 
I use _.unzip() several time.
yea.. alone it's meh. Combined with others in a _.chain() it's handy
 
I'll write up an example for you
 
zipping is best when you're merging promises
 
4:03 PM
and when you are done peeing
object-rest-spread isn't in es7, is it?
 
Stage 2
 
i think that means no.
 
Also, no engine has implemented it.. last i checked.. both implementations were transpilers..
 
I thought V8 has it in canary... I'll have to check that
 
yea, that's fine. i'm just making sure it'll be in a spec, soon
I could care less if my engine does it natively.
 
4:09 PM
it's on its way, it's just such a fringe feature that nobody is in a hurry
 
I think it's the bee's knees.
 
Nevermind, it is just Babel that has it
interesting
We use it everywhere in our code here
 
yea, me too.
sure... I can use Object.assign() for some of those uses, but this is much prettier.
or maybe I am confusing expanded object literals.. which one allows:
let newObject = { ...oldObject, newProp: 42 };
yea, that's object-rest-spread
 
:D
 
4:28 PM
const, you pleb
 
I don't const.
 
start consting, pleb
 
make me
 
make me make you
 
you can start telling people to use const when you start writing tests
 
4:35 PM
This "Crystal" brand hot sauce is actually pretty flavourful. A lot better than I anticipated.
@ssube For the record, I do write tests, I just don't like them.
 
"I just don't run them"
 
I run them as a part of our push process
 
Guys, I'm looking for an npm module that will
 
@littlepootis jQuery
 
Help me gain weight
 
4:37 PM
I stand by my answer
 
npm install npm
 
npm install *
 
There are websites that suggest I eat 3500 cal a day.
 
god no
You'll become obese if you do that
 
But I'm afraid that'll kill me
 
4:39 PM
bike a couple miles with that and you'll be fine
 
no
 
@ndugger I do bodyweight workouts
But they're not working out for me
 
badum-tsch
 
Because I'm 112lbs
 
@littlepootis good god(s)
 
4:40 PM
sshouldn't the could to be healthy, not hit a certain weight?
 
Move to america, where everyone here gets fat by just eating regularly
 
yes, just stop moving.
 
Anybody has meteorjs setup?
 
@littlepootis You need to do low rep, high weight workouts where you're going to muscle failure. That builds mass.
 
@Abhishrek nobody does meteor, go away
 
4:40 PM
@Abhishrek talk to @corvid :)
 
However, if you want to slow down your metabolism, there are ways to damage your metabolism, but that's not good...
 
Whenever I am pinged, I think someone's gonna ask me about meteor
 
@ndugger marryjewwanna
 
@ssube well I find it hard to even look at
 
@Abhishrek What's up?
 
4:41 PM
@Abhishrek cause it's bad
 
@ton.yeung 165cm
 
@corvid recount your trauma for us, twice daily, to keep the noobs from using meteor
 
@ssube I was thinking more along the lines of eating ~700 calories a day for about a month, so it slows your metabolism to a crawl, then you start eating regularly, and you'll start gaining fat
 
@ton.yeung Unit CM not recognized. Did you mean:
* radiation: Ci, Sv, Bq, Gy
* length: mi, in, ft, yd, ls, ly, rd, pc, AU
* time: yr, hr, wk
* counting: nt, bp
* luminous_power: lm
* mass: lb, AMU, kg, Da, dr, st, tn, ct, oz
* volume: pt, tb, cu, qt, bu
* resolution: px
* pressure: ATM, Pa
* charge: Ah
* speed: kt, kn
* prefix_only: dz, gr
* logarithmic: dB
* solid_angle: sr
* energy: th, Cal, Wh
* luminosity: cd
* power: hp
* viscosity: St
* frequency: Hz
* magnetism: Oe, Wb, Mx
 
@ssube I actually wrote an article on it because I had to repeat it to many people
 
4:42 PM
@corvid I might ping you, trying to help someone using meteor
 
> And the thing about Meteor.js is it's got lifeless eyes. Black eyes. Like a doll’s eyes.
 
Meteor js ships with an installer
it loses me at that point
 
@ton.yeung cool. But are you thin af like me?
 
@Abhishrek Yeah that part is pretty dumb. You can run meteor build to make it into a Node.js app for deployment
 
4:44 PM
@corvid well I am trying to setup auth0:lock
 
you can beat meteor just by glueing together a bunch of micr-frameworks
 
and the github users like auth package
 
@ton.yeung do you plan on gaining weight?
 
Which version of meteor are you on? If you're on 1.3+, just download the NPM equivalent package. Don't bother with atmosphere packages
 
@littlepootis steroids
 
4:45 PM
@ton.yeung nope
 
I'll never be 112 lbs unless I become a quadruple amputee and get cancer
 
@Luggage you can't inject steroids into bones
 
@Luggage With my height and viking heritage, the only way I'll get to 112lbs is after a bit of decomposition.
 
That was what I was going to write first and decided to come up with a scenario where I was still alive
only no vikings
 
@ton.yeung ah, thanks
 
4:49 PM
There's 2 types of people in this world; those with viking heritage, and plebs.
 
@littlepootis not with that attitude
 
@ndugger What about mediterranean heritage? At least there's better food there
 
pleb
 
@ton.yeung I joined a swimming class a few years ago, but my skin couldn't handle it. So thatsnot an option.
 
I guess Danish heritage does lead to larger size..
 
4:50 PM
Your skin couldn't handle swimming? wat
 
do you even have skin bro?
 
@ton.yeung that's basically what I've been doing for months
 
that wasn't skin that fell off, it was dirt.
 
@ton.yeung not sure why. Allergies.
I don't.. like water
 
maybe it's the chlorine
 
4:52 PM
@littlepootis have you tried the ocean?
 
@littlepootis do you have Rabies?
 
No, just cancer
It's probably chlorine sensitivity
 
@littlepootis maybe it's just the water in India. They probably sanitize it with curry.
 
@ndugger lmao
 
@ndugger no, dead bodies
 
4:55 PM
@ssube true
 
3E04:4018][2016-07-01T12:50:19]i301: Applying execute package: SetupMeteor_UserInstall, action: Install, path: C:\Users\abhis\AppData\Local\Package Cache\{2DA24988-287C-4531-9B32-88729CBDF7F1}v1.0\SetupMeteor.msi, arguments: ' ARPSYSTEMCOMPONENT="1" MSIFASTINSTALL="7" METEOR_DIR="C:\Users\abhis\AppData\Local\" INSTALL_REG_PATH="SOFTWARE\Meteor Development Group \Meteor\Install" MSICUSTOMERRFILE="C:\Users\abhis\AppData\Local\Temp\Meteor_20160701125018.log.err" PERUSER_INSTALL="1"'
[3E04:4018][2016-07-01T12:55:02]e000: Error 0x80070643: Failed to install MSI package.
@corvid ^
This whats frustrating me :-|
 
@Abhishrek can you run meteor version and see what it says?
 
this is the msi installer
can't even get to meteor cli atm
 
His installation failed
 
This is hillarious and sad
I'll just ssh into my nix vm and install there :-| if it fails again
 
4:57 PM
Ah okay... I think I read recently that the MSI installer was broken. Have you tried installing an older release? I would say try 1.3.1 or so
 
don't dev on windows
just don't
I like windows but still noplz
 
@ssube yeah yeah yeah, I know all that
but If I want to reproduce an issue with IE * for me its fastest to use windows
 
ALso don't use meteor
just because
 
@Abhishrek or just hit your VPS...
 
yeah thats what am gonna do
but then testing requires opening a port
and all that blargh
 

« first day (2085 days earlier)      last day (2868 days later) »