« first day (2754 days earlier)      last day (2191 days later) » 

3:00 PM
We get that the mods are divided and somewhat pissed but I don't think it's helpful to vent here :D
 
@BenjaminGruenbaum Yeah I told @MadaraUchiha if he ever tires of my shitposting he can give me the boot
 
@BoltClock lol
 
it's a coping mechanism
 
meta.stackoverflow.com/questions/366969/… I had a feeling this wouldn't go away
 
How I feel about inclusiveness: youtube.com/watch?v=OQSNhk5ICTI
 
3:02 PM
What is different about this post than her other rants? :/
 
full on...
 
SO's a Q&A site, not a social network.

All of these posts are like people screaming at wikipedia to be more inclusive
Like... it's an encyclopedia
 
the chat side does get more blurry
 
But what about double rainbows? I've seen a few double rainbows on here. It's totally related to inclusiveness lol.
 
@SterlingArcher She may as well have just posted the entire thing with bold text tbh.
Also, the general tone of that seems..out of character for a mod. Like, I get passion and all, but, yikes.
But I could certainly be wrong there.
 
3:04 PM
> OK, now I stay offline for the next 12 hours and let the outrage flood in.
The hawins strategy
=D
 
Oh, hi Service Worker in MS Edge. Status: complete!
About fucking time
 
I feel like this follows me where ever I go.. I quite facebook because of drama both with facebook and my friends on facebook.. Now stack overflow is sjwing (not saying I'm against it, just that I don't know what to say) and I'm astounded.
 
what idea was that?
 
@Cereal The first comment to that said it succinctly, as well, the post is getting downvoted, so I guess the site is 'working as intended' but like before, there are people who look at that and say "LOOK, SEE HOW UNWELCOMING YOU ARE FOR DISAGREEING WITH ME!!!"
 
oh
 
3:06 PM
@BenFortune 👍
 
I mean, it's an impossible argument.

Everyone already here clearly wasn't daunted by the attitude of the community. That's why they're here.

Everyone else clearly was
 
@SterlingArcher I hadn't seen that, presumably because it got downvoted so quickly
 
@Cereal I honestly was. I took me a long time to want to do anything on here, but I "sucked it up buttercup"...
But then again, the fear to contribute might be part of why the answers are generally quality
 
I hate drama, and I'm finally participating on meta because of this.
 
I honestly wonder if the site is near eol though. Kind of like COD when everyone is 10th prestige the new has to come out lol.
 
3:09 PM
EOL? Eh, but a lot of more regular users complain of 'question stagnation'.
 
If the goal was the have an answer for every question, and the biggest complaint boils down the "Too many duplicates", then I'd say it's reaching its goal, not dying
 
maybe not end of life, but something close. Recently, my problems stopped being solved by SO.
 
Except that reaching your goal in this case means you lose all your investers
 
I liked Tim Post's answer to that one.
 
thanks @Feathercrown :0
:)
 
3:13 PM
what just happend lol?
 
poof
@DavidKamer have you tried Exploring ES yet? I think it's a genuinely great book
 
can you reshare the link?
 
guys :| I have no idea what I am supposed to be doing
 
I didn't honestly even see it past the red in my eyes yesterday lol. Once again, I apologize. I do know some advanced JS, but I tend to forget basics sometimes.
 
@BenjaminGruenbaum lol
Very inclusive
@corvid Congratulations, you're a professional programmer
 
3:16 PM
@DavidKamer sorry if I was being hard - exploringjs.com
FWIW, when @MadaraUchiha came here we all made fun of his JS, it took him a year but he got way better :D
 
ooo, I'm real bad at it too
 
@MadaraUchiha's code still sucks
 
Me too
I'm moderately sure if any of you saw the project I'm working on, you'd have an aneurysm
 
@SterlingArcher that's a bit rich coming from you :P
 
My code is flawless
 
3:18 PM
@SterlingArcher I become very motivated at times to reach out to his former colleagues at Taboola and ask for gems :D
 
Translation: I haven't noticed any of the flaws in my code.
 
@BenjaminGruenbaum I spend the last few months going through an online boot camp and I learned ALOT that I had no interest in before hand. I love JS now, but I definitely don't have years of experience. I've spent most of my time with Java, C++ and Python. I wasted a lot of time on PHP lol.
 
I'm in the process of starting to learn C++
I tried Rust, and it was too painful
 
@DavidKamer the important take away from yesterday is that we're all still learning and learning is the better attitude.
@ndugger I recommend Bjarne's book
 
3:19 PM
Never heard of him, or books
 
@Luggage Check the last Paragraph and sentence of Nicol Bolas's answer, damn..
 
I don't really learn from reading books; it's too tedious
I usually just learn from trying stupid shit out and watching the compiler fail
 
@hilli_micha don't know who that is
 
This is true. I get caught up in the cool stuff I know how to do and think I've figured it all out. Alot of my knowledge of the basics is implicit, so a review is always good. To quote the zen of python "explicit is always better than implicit"
 
3:21 PM
@ndugger Same, I can only learn by figuring out everything that doesn't work
 
Anonymous
 
which only leaves what works
 
@KendallFrey plethora
 
@JayIsTooCommon Implicitly
 
Anonymous
linky context? or is it long term?
 
3:22 PM
let's not get back into that here
Feel free to read the transcript from the past 5 days
 
Anonymous
ah, that bad. alright.
 
no, just a constant topic recently.
 
tbh, if you're really inclined, the open issue on the JS Github by Ben is a good primer.
 
^
 
The only thing I'll say is that you should self moderate because this is public. There have been many of devs blacklisted, especially in the game industry because they are perceived as a bigot by their community. Kingdom Come had a small scandal about that... I digress lol
 
3:24 PM
Hello. Is it possible to override the behavior of for ... in on a custom class? I'm writing a collection class and it has some properties I don't want it iterating over.
 
Anonymous
@hilli_micha cheers
 
I think js has generators now, so you could write your own generator, right?
 
developer.mozilla.org/en-US/docs/Web/JavaScript/… says some properties are marked as "not enumerable" but I'm not sure how to set that flag on my own properties
 
Override the behavior, no, but you can iterate in different ways.
 
3:25 PM
@Cereal yup
 
@Cereal in, not of
 
Oh well, maybe it'll give him ideas
@Kevin
 
ohh, he was replying to the for..in question
 
that's what I'm reading right now
and I read that one last year
like in december, but I know most of that stuff from a few years back and wanted to review bc I was starting my own business
 
@KendallFrey Ah, I just learned about defineProperty this morning when I was trying to implement getters/setters. Good to know they're useful for this, too.
 
I've never read a programmer book or done a programming course
 
I just finished that, and that's where I learned es6
 
I can't even make it through entire blogs
 
I should probably learn about generators while I'm at it
 
That's probably why all my code's so shit
 
3:30 PM
I actually kind of miss working retail at barnes & noble
It was a decent gig
 
It would seem very hard to obstruct justice for a crime that never happened! Witch Hunt!
lol?
 
I ran the music department
I got to choose the music to play in the store
 
@KendallFrey there was a good article/study about how American politics is basically a team sport now
 
I remember getting shit from coworkers for playing Train over the speakers
 
A zero-sum game, almost
 
3:33 PM
@KendallFrey I honestly don't care about it anymore. That's part of why I left facebook. If I do care about something, I don't plan on saying it. Both sides seem fascist when you don't have a strong opinion either way. What ever side you talk to will nearly kill you for not agreeing with them.. even if you aren't disagreeing lol
"let's agree to not necessarily agree or disagree on that one"
 
isArray.forEach synchronous?
 
@ggb667 depends on the callback I think
it itself is synchronous? Right guys? lol
 
It doesn't hit every element in a separate thread or anything. You could use an async iterator and it would run the iteration in another thread if you wanted to
 
//like you can do
arr.forEach(async ()=>{dostuff});
 
3:37 PM
yeah, that would return immediately, and iterate in another thread
 
actually
I've only seen that with map
@Cereal that makes sense. Really only useful in node from a programmatic prospective?
 
No, you could do that for applications
 
yeah, I don't know where I was going with that lol
 
items.forEach(async (i) => i.sendToServer());
 
Do "thin mints" affect your short term memory even afterwards?
 
3:39 PM
Or whatever
 
Ugh
Really?
 
yeah, @Cereal that's a clearer example
 
Huh, that pinged me
I didn't think partial names pinged
 
eh, no, it just highlighted
 
really??
 
3:40 PM
@ndugger never heard the stereotype about the burnt out cookiehead that it permanently forgetful?
 
Yeah, notification and everything
 
@Cereal that's the whole reason why I changed my username to ndugger; there was like 4 nicks in here at one point in time, and the pinging system is broken as fuh, so I had to change my name
 
arr.forEach(async ()=>{dostuff}); isn't useful.
 
they must be using a regular expression that matches biased on partial strings. I wonder if someone else that started with Cer would have got it too or if it would match on Cer^ at that point
 
3:41 PM
@ggb667 Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
 
@ndugger Do you think if I changed my name to * it would ping me on everything
 
use .map instead, so you can then use promise.all on the returned promises.
 
@Luggage I swear, I snapchatted this girl something, she replied "I'm coming with", and I honestly don't remember where she's coming with now, lol
 
@KevinB if you are showing where to place async?
oh
 
It all happened in like 5 minutes
How I forgot so quickly, I don't know
 
3:41 PM
Did that work?
 
1 message moved to Trash can
@ggb667 Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
 
was it real?
 
yeah, that's why I clearified by saying "I've only seen it with map" lol
 
@KevinB it is if you don't care if they succeed or not =D
 
using .forEach throws away the returned promises, at that point they might as well not have been async.
 
3:42 PM
Yes, it was real. It just happened.
 
 let  retval = false;
 response.result.Event.forEach((element) => {
   if(moment(element.startDateTime).isBetween(beginDateTime , endDateTime, null, '[)')){
     orderItem.eventId = element.eventId;
     orderItem.resourceId = element.resourceId;
     retval = true;
   }
 });
 return retval;
Will that do what I want?
 
yeah, you can't do that
 
> naming variables "retval" -- why the fuck do I see this everywhere I go?
NAME YOUR VARIABLES PROPERLY PLEASE
 
retval = return value
 
yes, but that's an awful name for a variable
 
3:43 PM
No method you use will allow you to return retval directly (other than sugarcoating with async/await, but you're still actually not returning retval directly)
 
I can't understand whate you're doing, but I think you probably want filter or something like that?
 
assuming moment(element.startDateTime).isBetween was asyncronous
but isn't that synchronous?
 
maybe some()?
 
if you're not doing anything asynchronous, there's nothing to worry about
 
Should I use a more regular `for (let item of listOfItems)...` loop (edited)
with a `break` or `continue` statement
 
3:44 PM
the order of operations there is 1. retval = false, 2. return retval (false), 2. retval = true (false was already returned)
 
a for loop would let you return directly
 
you could do a find, and check for null
 
no need for continue/break etc, you just return when you have the value you want to return
 
let result = response.result.Even.some((element) =>(moment(element.startDateTime.....
actually filter
 
3:46 PM
const urMum = response.result.Event.find(e => moment(e.startDateTime).isBetween(beginDateTime, endDateTime, null, '[)'));

if (urMum !== null) {
    // ur mum
}
 
replace some with filter and you'll return the matching element?
 
I like my solution better
 
@ndugger I use retval. Old habit from before JS.
 
ferric chloride solution is best solution
 
@KendallFrey CsOH*
 
3:52 PM
Find only finds the first one?
 
Holy crap I left and the room blew up
You guys can't stay civil without me
 
No, the website blew up.
 
Good job guys you did it
 
JS leaves no survivors
 
I'm so confused by js.
I was going to go with
  let  retval = false;
  for (let element of response.result.Event) {
    if(moment(element.startDateTime).isBetween(beginDateTime , endDateTime, null, '[)')){
      orderItem.eventId = element.eventId;
      orderItem.resourceId = element.resourceId;
      retval = true;
    }
  }
  return retval;
Is that too old school?
 
3:54 PM
replace retval = true with return true; and remove the final return.
No need to continue looping once it's true, nothing sets it back to false.
 
@ggb667 that looks fine, I might create a generator for the moment part.
Also yeah, you can do return true inside the if and return false at the end
For that you can use .some
Or .find
 
I don't know forEach some and find at all. And I suck at promises.
 
@BenjaminGruenbaum you had mentioned something in the SO post about welcoming community moderation courses. Do you have any links? Even if I'm not a RO I feel like that could be useful to know
 
@ggb667 rtfm
 
let element = Array.from(response.result.Event).find(x => moment(x.startDateTime).isBetween(beginDateTime , endDateTime, null, '[)'))
// set eventId and resourceId if not undefined, return accordingly
 
3:58 PM
Reading is different than stick time.
 
sure is
 
I have read about 20 articles on promises and still don't get it.
 
MDN is going to generally be your best source for everything EcmaScript
 
@ggb667 Just wait until you get to observables
 

« first day (2754 days earlier)      last day (2191 days later) »