« first day (1990 days earlier)      last day (2941 days later) » 

2:08 PM
I want this in Chrome :(
 
@MadaraUchiha That makes my pants shorter.
 
^ WANT
 
Can you require jade files, short of webpack? (Webpack might be overkill for my simple app)
 
no
 
@SterlingArcher you doing React yet?
 
2:23 PM
Nah, mostly angular
I'm helping develop that game I used to play again, so I'm working with PHP too
But they overhauled the system so we're using angular and PHP7 now, with a docker dev build which is super awesome
It's a proper dev team.
 
pkill foo
killall foo
ps -ef | grep foo
// foo is still running....
o_O
 
foo is evolving
 
or has a parent watching over it
making sure it eats it's cheerios and stays running\
 
Uptime says it never stops
 
I love cheerios
 
2:33 PM
gross
 
Mine have to be honey nut
 
@rlemon how root are you?
 
249
Q: What if 'kill -9' does not work?

TshepangI have a process I can't kill with kill -9 <pid>. What's the problem in such a case, especially since I am the owner of that process. I thought nothing could evade that kill option.

 
2:34 PM
@ssube Oak
@apsillers yea kill -9 works. just odd that pkill didn't (to me)
 
my eye hurts
 
Dude it's just groot
 
kill -9 is special
 
I'm sure Groot has a little maple tree in his lineage
 
his mommy said so
 
2:36 PM
kill -9 is annoying because I need to know the pid
 
This makes me sad :-( ^
 
the uppercase method names are annoying
 
the source is even more annoying
If.prototype.Then = function(handler) {
  this.condition && !this.executed ?
    this.call(handler) :
    void(0);

  return this;
};
 
i'd screw that up every time
 
2:37 PM
ugh..
 
That's awful
 
hi
 
2:39 PM
LMAO
I thought it was a joke at first
 
@FlorianMargaine ha we found that one at the same time..
 
now, what would be funny as hell: pakage requirements: is-thirteen
LMAO
 
@Neal yeah, just 2 minutes earlier
 
@FlorianMargaine ;-P
 
2:41 PM
found it this morning, just went to fetch the link...
 
atleast the 5 one is clearly humorous
the is-thirteen is just .... why
 
@GregBorbonus it is humorous too.
 
five.map([1, 2, 3]); // [5, 5, 5]
 
I know
 
@GregBorbonus And the If one is just.... just.... WHY?!?!
 
2:42 PM
five.oclock(); // '🕔'
omg
 
see, the 5 one funny
 
the funniest one is this:
  five.tooSlow = function() {
    var returnIn = new Date(new Date().valueOf() + 555);

    do {} while(new Date() < returnIn);

    return five();
  };
 
ohh dear god
 
@rlemon pgrep
 
that has to be the worst way to sleep that I've ever seen
 
2:43 PM
pkill -9 "part of name"
or pgrep for grep syntax ^
@rlemon ^
 
@GregBorbonus it's not a traditional sleep, it's a busy wait, and you'd be amazed (to tears) by how many codebases it shows up in
we ended up dropping omniture for a real analytics tool because they used a number of those waits
 
ohh, I believe it. Too many people have wanted a core javascript sleep function.
 
What I don't get is why use it, when all you have to do is setTimeout(function(){do your cap here}, WAIT TIME IN MS);
 
Why do all the newest and shiniest javascript frameworks look so... ridiculously overcomplicated? :\
 
2:51 PM
I have rewritten a ton of my own code to use setTimeout, rather than a sleep function or whatever
 
@GregBorbonus that's async and async is hard
 
if you're righting something that is to be used by other people and you call it a library or framework, HARD is what you do
and do it right
 
do you think React.js is special and a staple or is it just a new and shiny flavor of the quarter?
 
or don't put it out there.
 
Comparing to objects, MDN says, trailing commas are forbidden for JSON. Any example?
 
2:54 PM
Also, what happened with famo.us anyway? It looks completely different than it originally started
 
@JoJo neither. It's good because it's really good at making the DOM fast. It's just a particularly well-scoped, well-implemented library.
@overexchange the spec
 
@ssube ty that is my basic understanding, its like some sort of DOM engine that you inject to make views faster?
i could get into that for sure
 
@JoJo no. It combines the event handling, templates, and DOM/render parts of views into a single library. Because they're all being handled in the same place, it can batch changes (render more efficiently) and match events to what your template thinks should happen.
They took the three big DOM touch points, put them in one place, and used that to make the lot much faster.
 
awesome
 
@FlorianMargaine made me remember sleepSort
 
2:58 PM
But unlike Angular, didn't stomp all over everything else.
 
function sleepSort(stack) {
	return new Promise( (resolve, reject) => {
		let ret = [], len = stack.length;
		const org = item => setTimeout(adder.bind(null, item), item);
		const adder = item => ret.push(item) && ( (--len <= 0) && resolve(ret) );
		stack.forEach(org);
	});
}
 
@overexchange trailing commas are proposed in ES2017
I'm not entirely sure if that applies to JSON
 
@ssube nice that is good to hear
 
JSON is its own standard, through RFC
trailing commas are the mark of the beast
 
Thought so, I wanted to say no
 
2:59 PM
@rlemon that one was different
 
@FlorianMargaine yea, still made me think of it
 
I prefer the bash version
 
So even with ES7, a trailing comma in JSON will still be illegal, correct?
 
@SterlingArcher it'd better be, or I'm going to rage quit
become a truck driver
 
@ssube if you make an object JSON in JS, and it has a trailing comma, I would hopefully assume it would be removed
 
3:00 PM
oh yeah
I love a trailing comma...
 
so guys i think in this code they are trying to allow for a flash background. What is going on with the clone().html()? $('#contentBox > div:first-child').prepend($('.preview .templateOption2Background').clone().html());
 
JSON sucks
 
I'm not a big fan of the trailing comma proposal. Makes no sense to me
@FlorianMargaine XML 4 lyfe
 
@SterlingArcher go away
 
so I have a basic understanding to start with
 
I'm here to stay bae
 
SEN4lyfe ^^^
 
What on earth ._.
 
@JoJo think of what would happen if you said "get this element and prepend it here"
 
@JoJo, so you're cloning something, then getting the clones html and injecting it?
 
3:02 PM
vs "get this element, clone it, then prepend the cloned HTML here"
 
it would move it
 
> (In the off chance jAndy reads this: The Game)
@Zirak you're a cruel man
 
@JoJo Why not just get the html
 
@SterlingArcher an object doesn't have any commas anyway
those only exist in the source
commas aren't real, man
 
@GregBorbonus or just pass the cloned object
either would copy it instead of moving it
 
3:03 PM
kk
 
How Are Commas Real When JSON Parses Trees
 
@rlemon true
 
but one I think retains events (the clone, without the HTML)
 
your face isn't real
 
but the current double work is not really useful
 
3:04 PM
it never tells me what it is cloning though
 
the jQuery collection uptil that point
 
How is it supposed to tell you?
 
kk, the element
ty
 
$('.foo').clone().add('.bar'); clones .foo elements then adds in the .bar ones
 
k
 
3:04 PM
@FlorianMargaine it took me forever to get used to them in puppet code, but now I can appreciate the ease of moving lines.
 
$('#contentBox > div:first-child').prepend($('.preview .templateOption2Background').clone());
 
gotcha
ty
 
@ssube yup. I especially like them in python.
 
will clone $('.preview .templateOption2Background')
 
and then prepend it
 
3:05 PM
yes
 
@ssube this, specially in git diffs
 
$('.preview .templateOption2Background').clone().prependTo('#contentBox > div:first-child')
 
@rlemon I thought you were over the foo/bar phase
 
nicely rewritten
:D
 
@FlorianMargaine I haven't written Python in months and it makes me happy.
The syntax has always felt so awkward.
 
3:07 PM
return [{"derp":1},{ "foo":2},{"poop":true},];
 
Ahh, trailing comma.
 
trailing comma
 
If you returned this JSON to say, Node or Java or something, will that trailing comma be removed in the new ES7?
 
!!> [[1,2,3,4,5,6,] + [7,8,9], [1,2,3,4,5,6] + [,7,8,9]]
 
@rlemon ["1,2,3,4,5,67,8,9","1,2,3,4,5,6,7,8,9"]
 
3:09 PM
Or will returning a trailing comma break everything
 
seems JSON.parse does NOT like the trailing comma
 
leading comma is more useful anyways :D
 
@SterlingArcher no, it breaks.
 
JSON.parse('[{"derp":1},{ "foo":2},{"poop":true},]');
VM1377:1 Uncaught SyntaxError: Unexpected token ](…)(anonymous function) @ VM1376:2InjectedScript._evaluateOn @ VM216:878InjectedScript._evaluateAndWrap @ VM216:811InjectedScript.evaluate @ VM216:667
JSON.parse('[{"derp":1},{ "foo":2},{"poop":true}]');
[Object, Object, Object]
 
3:09 PM
JSON cannot have trailing commas. JS isn't supposed to.
 
@ssube GAAHH then what's the fucking point D:
 
there isn't one
 
@GregBorbonus you probably have to transpile that with babel on Canary.
 
JSON states with no ambiguity that a comma may only come between a pair of members within an array or object: json.org
 
3:10 PM
Actually I don't think trailing commas are supported anywhere yet
 
this talks about the effect on.... simpler diffs in version control?
I am unconvinced
 
DONT PAY THE FERRYMAN UNTIL HE GETS YOU TO THE OTHER SIDE is the point
:)
 
@SterlingArcher What?
 
@GregBorbonus ES2017 trailing comma support is a proposal
 
3:12 PM
aha
@rlemon I've defeated your friday image clickbait
 
I would seriously hope that trailing commas in an object literal wont break JSON return from JS
 
> JavaScript is a lazy language
 
I can see many noob questions arising from that
 
ever write useless code just because?
 
!!s/(lazy) (language)/$2 for $1 people/
 
3:14 PM
@AwalGarg JavaScript is a language for lazy people (source)
 
!!> const concat = (a,b,c) => (a+(b.unshift(c),b)).split(','); concat(['a','b','c'], ['1','2','3'])
 
@rlemon ["a","b","c","1","2","3"]
 
aright kids, I'm trying to language lawyer this answer but can't find enough references to how module exports actually work
0
A: Importing something that's not explicitly exported by a module in Javascript

ssubeNot using the module API. A module exports an object and any code importing the module is given a reference to that object ("reference" in the JS sense). Section 15.2.3 of the spec covers exports and, very verbosely, shows that the export keyword is used to include some local variable in the mod...

 
ohh, I like it
 
3:23 PM
@ssube stackoverflow.com/questions/36265330/… free rep if you're willing to go into detail about JSON and trailing comma support
 
Any issues with appending the head element with a stylesheet?
 
(I figured it would be a decent main question among the shit)
 
@SterlingArcher I like the idea of ignoring the trailing comma, but when they make that change, I think they should also make semi-colons needed for js code
 
For client side, I think semi-colons should be required always
 
absolutely.
I code a lot in php
 
3:24 PM
so you're saying they should remove an entire section of the spec? (ASI)
 
so, when I write JS, I'm adding semi-colons anyway
just out of habit
 
For Node, I "get it" why some decide not to use it, but I still do it anyways
 
@FlorianMargaine yes and no
yes, because ASI is fucking stupid (because people rely on it), no, because it would break a lot of the web :/
 
well, JSON is not code specific, you use it in many languages, and if we have rules that apply to things that span multiple coding languages, why don't we have rules that also span multiple coding languages.
 
Well, like @ssube said JSON is supported by RFC, not any specific language
 
3:27 PM
like, if you're going to develop any code, here are the guidelines all base languages share:
I hate having multiple comment deliminators
and seeing some code use semi-colons while others don't
I mean, an array in JS, php, C, ruby, bash .... an array is an array
why aren't standards shared as well?
just my 2 cents.
 
@SterlingArcher imgur.com/gallery/6Pj1E0g this is terrifying
 
OHHH GOD WHY
@ssube :D see, you gots reps
 
God, I hate it when you answer a question with a thoroughly written response, and the questioner just drops the question.
Stack should e-mail people that there was a comment/response to a question
especially when you write something so beautiful/
 
@SterlingArcher hooray, now I'll... be qualified to run for mod next year?
 
Obvi
I'm running again next year lol
Must. Beat. BJB.
 
3:35 PM
I don't think I would be a very good mod.
 
I would be great. I can be snarky, but I'm not a dick
Ok so maybe I'm a dick... but I'm not an asshole.
Ok so maybe I'm an asshole... but I'm not Canadian.
 
@SterlingArcher if you were Canadian, you'd be a polite asshole
 
Are you fucking sorry, eh?
 
you'd say things like "Please excuse the intrusion, but stfu"
 
Canadians say fuck a lot
 
3:38 PM
!!s/say //
 
@SterlingArcher Canadians fuck a lot (source)
 
gotta stay warm
 
> Are you fucking sorry?
the most Canadian thing to say, ever
 
@rlemon also, y'know, not die out
 
well yea but for that you only need like one or two good shags in your lifetime
 
3:40 PM
side note: I watched too much Letterkenny on the weekend again
 
!!afk lunch
 
> It's a hard life picking stones and pulling teats but sure as God's got sandals it beats fighting dudes with treasure trails.
 
4:04 PM
i like that
 
afternoon ^^
does anyone have any resources for learning or working with route planning and route suggestions?
even just theory, and not necessarily with JS
 
treasure tails?
 
hello what is the good js chart library at that time .answers i found on so is outdated
 
@SterlingArcher what that in response to my question?
 
d3 or webgl are good
 
4:12 PM
chart.js
is good
 
@AaronHarding no ._.
 
hehe okay
 
ok thanks
 
This is probably a really simple question, but how do people usually check if options are provided as the last parameter to a function?
 
@corvid define options
 
4:15 PM
As in, you have a function that has an arbitrary amount of strings as the first parameters, and then an options object as the last parameter. Does this make sense?
    const args = Array.from(arguments);
    const config = _.defaults(typeof args[args.length - 1] === 'string' ? {} : args.pop(), {
      timeout: 5 * 1000  // how long to wait before throwing error
    });
 
Personally I would just have the options as a second param
Would make your life much easier
And you can just spread your args
 
const args = [...arguments]; //i think
 
Wouldn't they have to provide an array as the first parameter though?
 
Are they not?
 
4:18 PM
lol interesting @Abhishrek
mechanophilia
haha
 
good reviews so far
hey @SterlingArcher
dude, so disappointed by AA album
I'm already ready to move on to listening to something else
 
I know man :(
Only like 4 good songs
Have you listened to After the Burial's new song?
 
no, I'll check it out
 
!!youtube lost in the static after the burial
 
@corvid _.defaults(typeof args[args.length - 1] === 'string' ? {} : args.pop() what in the hell are you doing?
 
what am I supposed to be doing?
 
that's like the George W Bush of argument parsing
there's absolutely no reason to use arguments in ES6. That's why some new function types don't even have it.
 
how about the icons on the HNQ list
lot of hot 3D questions today :)
or how about all site icons, everywhere
 
You can still use arguments in ES6 to check if a specific argument was passed or not. Function arity doesn't work that way.
Mostly you do that in library code though
 
4:27 PM
@apsillers I jsut noticed that. My notifications are all from SE now
 
Hey, nice instructions when I enter the chat
 
Wait... they say 3D not SE
 
@AwalGarg "check if a specific argument was passed"? You can't just skip arguments
for optional arguments, you provide sensible defaults
 
the 3D icon is top of the sprite sheet
 
Tight buttholes y'all, zigi is back
:D
 
4:29 PM
:D
 
Ignoring the text and stuff on the right, thoughts on this fiddle? I'm just interested in the JS, I tried to keep it all vanilla.
 
Chill
 
god, I hate course selection -.-
 
oh god, why are they using sprites
 
so there's a network-wide failure to adjust the sheet for each image
 
4:29 PM
@SterlingArcher why wouldn't they use sprites?
 
@ziGi you'd like the song above ^
@ssube I hate that with sprites you have to do like... section focusing to get an image
It's so weird to me
 
@SterlingArcher yep, you know me well :D
 
@SterlingArcher what? You mean, taking the sprite out of the sheet? That's the point of them.
You have one big well-compressed image, just like a single minified JS file.
 
Yeah but... what's wrong with separate images?
Don't you have to extract the exact pixel coords in a sprite?
 
@ssube someFunctionCall(getValueSomehow()) <-- this will always create a binding for the arguments object inside the scope of someFunctionCall, even if getValueSomehow returned undefined, which is different from someFunctionCall(). You might wanna know about caller's intention inside someFunctionCall, for which using arguments.length is a valid usecase.
 
4:32 PM
I am here to see what's going on, if the same people are still here, and to rejoin this joyous chat :D
 
Been working on any fun projects, zigzag?
 
@SterlingArcher it's yet another file. Plus, tiny images (like the monochrome kind sprites are often used for) can be really well compressed if you have a bunch of em. You can use pixel or percent coords.
@AwalGarg Why do you want to infer the caller's intentions? That's poor API design.
you may as well use caller and change the behavior based on who's up the stack, like Volkwagen did
 
I don't have a list of cases where such an inference is justified, but you always have edge cases. Dismissing them as poor design is quick and easy.
 
If you can find an edge case where using arguments as a sparse array actually works better than defaults and destructuring on real arguments, I'd be very surprised.
 
I'd remember to ping you next time I encounter one ;)
 
4:36 PM
hooray, no more pings from Awal! :D
 
Meta is broken
 
Complain on meta.meta.so
 
Hey there guys. Any ReactJS guru who could take me some noobish doubts?
 
32
Q: Why didn't Bellatrix use Legilimency on Hermione?

blehWhen Bellatrix found Harry and Hermione, she finds the Sword, and tortures Hermione to see if she took anything out of her Gringotts vault. Couldn't she have done it 10 times quicker by using Legilimency?

anyone else getting an error on that page ^?
 
4:39 PM
Shits down
 
o.O its the same on all posts on all sites
 
> Yes, we do look at every error. We even try to fix some of them.
 
Stack is now effected
There goes my workday
 
It's ALL sites.
 
I wonder how spammers feel like when stackoverflow is down
 
4:43 PM
inb4 programmer suicides
 
> In other news... tech companies across the world experienced an 84% decline in code production
 
@littlepootis India would suffer a great depression in the absence of Stack Overflow :P
 
@SterlingArcher max number of concurrent downloads from a single origin makes sprites faster too, until http2.0
 
what happen?
 
4:49 PM
Is there an estimated guess on the production impact of StackOverflow going down on a typical business?
 
@SterlingArcher depends on if the business is into it
 
> The meme that is displayed when something goes wrong on stackoverflow ... seriously.. where are there only white guys. Also why no girls?
 
@KendallFrey what does it do?
 
currently useful for: 1) opening rlemon's images that redirect to rebecca 2) tbd
 
4:50 PM
i don't follow :3
 
> Adds a context menu option to open a link as an image, rather than allowing it to redirect to a webpage.
 
@littlepootis fuck that guy lol
 
sure but does that even work?
 
@littlepootis indeed. why no girls? :(
 
yeah
 
4:51 PM
img src="http://google.com" ..
he he
 
> Reminder that we're hiring...
you say, as your website is half down
I'm not sure if that's good recruiting or not
 
well, its good that he is not the one responsible for recruiting... right?
 
How did StackExchange programmers fix a problem when SO, SE, SF are down??? How???
 
A production build fixing all sites is rolling out now. ETA: 2 minutes.
 
@KendallFrey I like it.
 
4:54 PM
@littlepootis they queried answers directly from the database
 
@littlepootis it's almost like some people actually know what they're doing
 
@Trasiva well that was worth the $5
 
@KendallFrey This means no more baited image links to Friday!
 
you just need to remember to always use the context menu
 
@KendallFrey that's what she said
 
4:56 PM
I always use the context menu. But still.. that guy..
 
@ssube I think that works better as a reply to your comment.
 
oh, it would
 
suggest me stuff to make with rust which is not related to graphics, and is not a screenshot taker for X11.
 
Hello world
 

« first day (1990 days earlier)      last day (2941 days later) »