« first day (1630 days earlier)      last day (3332 days later) » 

3:00 PM
palmella
 
@Deep If you need another search term 'linear interpolation'
 
cubic interpolation > linear interpolation
quadratic interpolation >> linear interpolation
quintic interpolation >>> linear interpolation
 
nth-degree interpolation > (n-1)th degree interpolation, yes we get it
 
septic interpolation >>>> public sewer
 
is septic interpolation some really clever way of saying that you're pooping?
 
3:08 PM
Lanczos resampling and Lanczos filtering are two applications of a mathematical formula. It can be used as a low-pass filter or used to smoothly interpolate the value of a digital signal between its samples. In the latter case it maps each sample of the given signal to a translated and scaled copy of the Lanczos kernel, which is a sinc function windowed by the central lobe of a second, longer, sinc function. The sum of these translated and scaled kernels is then evaluated at the desired points. Lanczos resampling is typically used to increase the sampling rate of a digital signal, or to shift it...
 
@ssube Pretty sure linear interp works more than fine here :)
 
@JanDvorak Thx
WOW I NEED A GF
SERIOUSLY
GUYS
 
@EnglishMaster try tinder, i hear good things
 
^ that
oh girlfriend you said? Sorry nope. Only fuckbuddies there :P
 
@EnglishMaster how did that suddenly came to mind so drastically?
 
3:10 PM
@EnglishMaster Seriously, we need to stop hearing about you needing a girlfriend.
 
3:30 PM
 
user1596138
@KendallFrey Wow
 
Hey guys does anyone have firefox on android
 
user1596138
Yes...
 
user1596138
People have that
 
I have an issue with it its not playing m3u8
Chrom plays m3u8 fine but firefix doesnt i tried beta and the org
Chrome
 
user1596138
3:34 PM
Isn't m3u a playlist?
 
woah no pings for me on Friday
@rlemon did yesterday I suppose, but @FlorianMargaine you are slacking
 
today's Saturday part 1 cool
 
@FlorianMargaine its good friday bro!
@rlemon haha
 
3:35 PM
 
lol
there better be no part 2
 
user1596138
lol yeah there are people walking down the street with 7ft crosses with wheels on them today. It's good friday
 
:P
 
haha
 
Yes its a playlist
 
3:36 PM
I hope she does a Sunday song
she has a good sense of humor, def respect for her making the Saturday song
 
her new album. SMTWTFS
 
lol that would be hilarious
 
user1596138
!!s/sense.*,/marketing team for managing to keep her afloat/
 
id buy it, and each day the song would be my alarm
 
@Jhawins she has a good marketing team for managing to keep her afloat def respect for her making the Saturday song (source)
 
3:37 PM
@Jhawins did she really have a marketing team?
 
her mom
 
Technically its suppose to since its part of html5 i just dont get it why it doesnt play
 
user1596138
Prob
 
user1596138
By the time Friday blew over yeah
 
user1596138
She signed to a label and all. She didn't jus record some songs and put on youtube
 
3:38 PM
@Jhawins it was still a choice she had to make
after all the hate/negativity she could have easily just left , or her life could have taken a drastically different path..
I mean the girl had to leave schools due to it
 
she got death threats and stuff from Friday
people be cray
 
internet people for sure!
if I catch my kids talking like that I will slap them silly
 
user1596138
I'm pretty sure the story goes her mom fronted some $4K to the record label or something. They helped her find the most raunchy annoying tune they could so she'd get heard and the rest is internet fail history
 
and be like.. why did you let me catch you?
 
user1596138
@Steve Download VLC
 
3:42 PM
posted on April 03, 2015 by admin

Hovertext: Also pukes on you a few times a day for about 1 year after installation. New comic! Today's News: GUYS! I'm gonna be on Science Friday today! Please tune in at 220 Central Time. 

 
@Jhawins I doubt anywould would willingly want to put their kid through that, I see it more as they did the initial video as something fun (thats what they claim) it exploded she got tons of negativity and had a shitty 2 or so years of HS and had to be pulled out, then they decided to make light of a bad situation instead of curl up into a ball and claim internet harrasement destroyed her life.
 
user1596138
@Loktar No? I'm pretty sure her mom paid a label to try and make that happen. But I didn't google it..
 
@Jhawins dude come on you think I havent watched the history on her? Her parents did pay the guy from Nigeria to produce it
but they didn't expect anything like what happened to happen.
also the guy from Nigeria (I can't remember his name now) didnt get rights to the video so thats how she was able to make money from it
 
user1596138
@Loktar I don't know what this video you speak of is. So I don't think you did or did not watch it :P
 
he learned from his mistake though and now gets full rights to the youtube vids as well
 
3:44 PM
@Loktar the one who smiles way too much?
 
@ssube yes
 
and was in the chinese food video?
 
yeah he produced that as well, and the thanksgiving one
 
user1596138
> Black’s mother forked over $2,000 for two songs written by Ark Music Factory’s team and one video, the now infamous “Friday.”
 
@Jhawins yeah 2k is nothing for that honestly
 
3:45 PM
Did you see her reaction video to Friday?
 
the roi on that 2k was way more than they expected.
 
user1596138
So anyway her mom chose it
 
2k is less than the video cost, guaranteed
 
@KendallFrey haha yea
 
user1596138
Paid for it
 
3:45 PM
@Jhawins yes... she chose the initial Friday video
 
arkmusicfactory.com seems like a run of the mill child star production company
 
user1596138
Why would she do that?
 
but she did not choose the for the internet to go crazy on her daughter hating her.
 
user1596138
Why would you spend that money
 
@Jhawins why not? If my daughter wanted to sing I would front money as well?
2k? Thats nothing for a professionaly done video
 
user1596138
3:46 PM
You would let your daughter sing Friday...
 
shocking! people love their kids!
 
@Jhawins that's how much your average mediocre music video costs
 
user1596138
You would pay $2K for a song like "Friday"
 
if my daughter wanted to sing I'd invest in soundproof walls
 
If she wanted to sing it, why would I care?
 
user1596138
3:46 PM
@Loktar They bought the song too
 
It was a catchy poppy tune
 
user1596138
She didn't want to sing it? She probably didn't know what it was until they'd already bought it
 
you can't possibly film and edit a 3 minute video for less than $800 or so
 
if I had kids I would support them in any career direction they wanted to take at 13
 
user1596138
I'm picturing one of those parents who sets things up for their kid, not asks them what they want set up.
 
3:47 PM
hell, you get a drone involved and you can charge $100/hour, easily
 
@Jhawins well Im picturing something different guess we will never know :P
 
user1596138
Jeez if my kid wants to sing I'll drop them off at the fire station.
 
planning on making some bank this summer helping friends out with filming
 
user1596138
Jk..
 
@ssube nice! I just read about the new proposed FAA regs they seem a lot better
for people who want to make money off of drones that is
 
user1596138
3:48 PM
Yeah the "JSON developer" here has a hexacopter drone he charges $85/hour
 
my plan is just to help film a few music video, particularly in the city and because they don't have any cranes or other equipment for that
 
user1596138
Also he has ~4Ksqft of office space to fill as of last week... So send startups to rural Indiana guys
 
got a gopro and a dji phantom sitting in the closet, a couple hours of filming and I break even on both
work on 3 or 4 videos and make a few grand to fly it around
 
user1596138
@Loktar your boss liked my resume so much he couldn't think of words to say ;P
 
@Jhawins he just had a baby
so idk where he is at with the interview stuff yet
I need to make new questions too :/
 
user1596138
3:50 PM
Haha oh nice
 
he asked me about them
said they are probably too basic for what we are looking for
I was like crap.. you're right
 
user1596138
Yeah I'm not worried about it I just thought to bring it up :P
 
user1596138
Oh yeah? New interview questions?
 
im actually at home today
I took today off
but yeah he had his baby like last THU
 
user1596138
Oh nice. Yeah I'm totally not bitching or anything, it's cool.
 
3:51 PM
ill paste in here what we would like, one sec
or the reqs I sent them to give to the contracting companies
 
user1596138
That means you're using recruiters?
 
-          Experience using  Node and npm in a front end environment
-          Familiarity with ES6/ES2015
o   Experience using transpilers such as BabelJS
-          Experience using build tools and JavaScript modules
o   CommonJS or ES6 modules
o   Understanding and experience with Browserify or Webpack
-          Experience building automated front end tasks using task runners
o   Experience using Gulp
-          Experience using preprocessors such as LESS or SCSS
o   Moderate to strong understanding of CSS able to take static designs and create accurate representations for the web.
@Jhawins they always do, in addition to recommendations from employees
 
user1596138
@Loktar Oh well shit
 
those are nice to haves
we will probably get someone with like 30-50% of that
but thats how it is with all job postings
but I need to come up with some questions centered around those :/
 
make em write an es6/less page and build it with gulp? tests for bonus points
 
user1596138
3:55 PM
Node in front end environment - no
ES6 - eh somewhat
Transpilers - no (is transpiler a real word?)
CommonJS - no
Gulp - no
LESS/SCSS - no
CSS - sure
Frameworks - they are frameworks I can figure them out
 
@ssube oooh nice I like that
 
@Loktar if they set up tests and coverage, hire them on the spot :P
 
hah yeah I didnt put anything for tests.. because I am shit with tests personally
so I didnt think that was a fair req
but if they did that.. yeah I would fight hard for them at that point lol
 
with gulp and mocha or karma, they're dead simple
karma with jasmine and require is not, so avoid that
(in general, jasmine is bad and require is meh)
 
user1596138
lol shittt I don't fit your reqs at all
 
3:57 PM
@Jhawins you have strong foundational knowledge
 
I wouldn't have fit the reqs at all when I was hired, either.
 
its hard finding anyone with that even
 
user1596138
Oh well. I was looking at FL based jobs recently but girlfriend kind of walked out Tuesday so I'm re-evaluating my stance again..
 
If you know JS and aren't someone who just knows how to $() stuff, we can tell pretty fast if you can pick this stuff up
 
@Loktar can you divulge the compensation? curious :X
 
user1596138
3:59 PM
Yea lol I got that foundation
 
@Mosho I wish I knew :/ I seriously have no clue, if I had to guess I could say in confidence > 70k and thats probably low balling
I think it depends on years of exp as well?
I mean I know what I make, thats the only thing I have to go on lol (and I make more than 70k)
 
@ssube there's gonna be a part 2, it's not really gone :D
 
user1596138
@Loktar lol deduct 10K for each req not met and.... I still want that hahahaha
 
@BenjaminGruenbaum posted anywhere?
 
@Jhawins haha
 
user1596138
4:01 PM
Err I mean.... That's close but you'll have to do better.
 
@Jhawins you havent done anything with node?
if you have at all you've used commonjs
 
@Loktar I would expect 70k to be for someone with under 5
but I don't know much either
 
user1596138
@Loktar Not in a front end environment
 
@Mosho also remember its location dependant.. I'm in the midwest, Nebraska
cost of living is pretty low here compared to the rest of the nation
 
user1596138
4:02 PM
I've used Node tho. I wish so badly that I had more excuses to use it here it was interesting
 
right
I'd live in Nebraska
 
@BenjaminGruenbaum that first one seems to be how java 8 did ::
 
80k in Omaha NE is equiv to 151,555 in SF apparently
according to cnn money calculator
 
lol wat
 
user1596138
@Loktar Ohhh I didn't know what common JS was
 
4:03 PM
Does anyone know how to reach an employee at the Chrome web store? I have an important update going out to 85,000+ users that's blocked.
 
@Jhawins var bob = require('bob');
:P
 
user1596138
lol yeah I get it now :P Didn't know the term
 
and you just run your code through webpack or browserify or whatever, and it resolves the deps on the front end
 
user1596138
I'm confident I could figure it out
 
so there is an easy checkbox for ya
 
user1596138
4:05 PM
Just haven't actually used browserify or webpack
 
we use LESS, which accepts vanilla css, so.. you could say you "know" LESS
you can pick it up as you go
 
user1596138
Haha
 
I could never go back to CSS after using a preprocessor
 
ES6 we just started using in the last 3 months with babel, main things Ive used it for are template strings, let and destructuring
 
Hey guys, I was wondering the best way to FIRST create a secure random token that when a particular link gets clicked in my site the visitor gets sent to another site I can pass that site the token so when the user gets there they can bypass an agegate and end up on a particular page.
 
4:06 PM
@TikaL13 Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
@Mosho same here man
 
I'm so much happier now that I don't have to write CSS (or any variant)
 
@ssube woah
how did you manage that?
 
have enough work running our dev tools that I don't really do frontend stuff anymore
it's fantastic
 
oh nice
I say nice.. but id hate that, I love frontend stuff
 
4:14 PM
get to spend all day managing gitlab/nexus/teamcity, writing gulp builds, figuring out test reporters, that sorta thing
 
Id rather have someone do the dev tool stuff for me :P
 
aw man, I love tooling and automation
 
Ill admit doing the taskrunner stuff is fun
but its so short lived for me usually
spend about a day or two getting all my tasks done and then thats it :/
we have someone else who does all the server automation/builds
 
the devs mostly do their own task runners, except when they screw up
I do get to use all the latest stuff for our internal tools (CI dashboard and whatnot), which is cool
it's never going to prod, so nobody cares what it's written in
 
thats cool to have that freedom
 
4:18 PM
on the other hand, we run 40-60k tasks/month on the ci server, so people are always complaining about something
roughly 1/3 of those are builds, so 10-15k builds/month
 
m59
@FlorianMargaine Should I use your wrapper, rather than Docker? I'm on the verge of needing to learn something like that.
pros/cons?
 
user1596138
4:41 PM
0
Q: Differentiate between property and method with same name

Kid DiamondIf I have a variable named format and a method with the same name, how would I go about calling the variable, and the method? use strict; function Time() { this.format = 'x:y:z'; } Time.prototype = { format: function (format) { } }

 
user1596138
"I wrote bad code"
 
@BenjaminGruenbaum I like how you linked this chat room in your profile as "Stack Overflow Gold Account". I was reading your answers from search results and got curious about your profile, so.
 
Hey, can someone answer a quick question about Mongoose/MongoDB?
 
whats wrong with this webpack config?
{
  context: __dirname + "/app",
    entry: "./client",
    output: {
      path: __dirname + "/dist",
        filename: "bundle.js"
    }
}
entry: "./client",
     ^
SyntaxError: Unexpected token :
 
m59
no comma
 
4:46 PM
?
 
m59
},

entry: "./client",
 
I'm working with subdocuments in Mongoose. What is the best way to search through them given a parent document and a single value inside the subdocument (not ID)?
Should I just loop through?
I have a subdocument array.
 
@m59 the commas is there no?
 
m59
What?
 
i am not missing commas
 
4:48 PM
Yeah, I see the commas.
 
m59
Yes, you are.
}  <-----------------------

entry: "./client",
 
im officially confused :)
 
Not sure what @m59 means.
Can you paste a corrected version?
 
m59
PUT A COMMA THERE.
 
user1596138
lol
 
m59
4:50 PM
Wow.
 
user1596138
lolololololololol
 
Where?
 
user1596138
Garlic
 
m59
Is this still April 1?
 
im using this example:
https://webpack.github.io/docs/configuration.html
 
user1596138
4:50 PM
@m59 yes. It is. It has to be!
 
Is this a blue/white dress thing?
 
@m59 I think you're confused about what's his config object, and what's his output from trying to process it.
 
I don't even know what web pack is, but I see all valid commas.
 
webpack is processing it
 
m59
OHHHHH. Man
That was unclear.
@Retsam yep.
 
4:52 PM
Can anyone help with a Mongoose question?
 
@SuperUberDuper Silly question, but you're assigning that object or something, right?
 
is just in a file called webpack.config.js
 
You're not just literally copying that block into a REPL, right?
Oh, yeah, that's not going to work.
 
repl?
 
@SuperUberDuper REPL. E.g. your browser’s console.
 
4:54 PM
You can't just stick a JS object in a file and reference it elsewhere. You probably want that file to be a JSON, or you'll need to export the object or something.
 
ok, webpacks docs are a bit confusing
 
m59
@SuperUberDuper see the very first thing on that page.
module.exports = {
  // config here
}
 
I'm trying to create a function that represents calling a function with arguments after it, so call((a, b) => a + b, 1, 2) will behave like 1 + 2, can anyone find out why I get "TypeError: Undefined is not a function"?
 
function call(f) {
  f.apply(this, Array.prototype.slice.call(arguments, 1));
};
 
4:56 PM
lool
thx
 
The reason you're specifically getting a "missing comma error" is because it's not being interpreted as an object, but as a block of code.
 
Node v0.10.29; it works fine in chrome console.
 
@Unihedro You probably want to return that value; and it works for me. What environment are you using? Do you have arrow function support? Node 0.10 doesn’t have arrow function support, does it?
 
ok thanks guys
 
Bah, I should drop this idea altogether.
Thanks anyway!
 
5:08 PM
You can just use call(function (a, b) { a + b }, 1, 2) instead
But your function is very similar to reduce anyway.
[1, 2].reduce((a, b) => a + b, 0)
 
@Unihedro it's obviously useful: it's essentially how Function.prototype.call is laid out. Question is, what do you want to do with it that you can't use call for?
@poke that only works for summation and a few other simple operations, though
[...].reduce(f, 0) can't be applied to any function f
 
I'm feeling stupid, is there now something inherently wrong with IIFE's to create closures in loops, like this
Thing.find(function(err, result) {
    for (var i = 0; i < result.length; i++) {
        if ( something ) {
            (function(res) {
                async(res.url, function(err, meta) {
                    res.image = meta.image;
                    res.save();
                });
            }(result[i]));
        }
    }
});
 
if you wanted to get weird (and cause a ton of memory problems), you could do something like function exec(cb, ...args) { return args.reduce((c, p) => { return function (...args) { return p.apply([c].concat(args)); }, cb); }
it's a really bad idea, but does arbitrary currying via closure
(that example almost certainly doesn't work)
 
crl
@Unihedro missing a return?
even if it looks weird with a function called 'call'
 
@crl It's not helping. The crash logs still points to where I use the function, and for "undefined is not a function".
 
5:24 PM
@Unihedro My node gives me this: SyntaxError: Unexpected token >
I’m on 0.10.31
 
var add = function (a, b) {
  return a + b;
};

var call = function (f) {
  return f.apply(this, Array.prototype.slice.call(arguments, 1));
};

var sum = call(add, 2, 3);

sum();
That's the latest I have after hearing your advices. :p
 
morning
 
if you do a console.log(sum), you can see that the return value is already a number. And you can’t call a number :P
 
TypeError: number is not a function

Process took 55ms to complete
@poke Oh.
... dammit.
I'm an idiot. :P
Thanks so much!
 
Are you trying to implement a currying function?
 
5:27 PM
:)
 
@Meredith Yeah...
 
I got you
Hold on
 
@Unihedro mostly useless in real life, but howsabout:
function bind(cb, ...args) {
  return args.reduce((p, c) => {
    return function (...n) {
      return p.apply(this, [c].concat(n));
    }
  }, cb);
}

let f = bind((a, b) => a + b, 1, 2);
console.log(f());
 
var call = function (f) {
  return f.bind.apply(f, [this].concat(Array.prototype.slice.call(arguments, 1)));
};
^ Did you want to do that? :P
Then call(add, 2, 3) returns a function.
 
:O
 
pointless partial application:
function bind(cb, ...args) {
  return args.reduce((p, c) => {
    return function (...n) {
      return p.apply(this, [c].concat(n));
    }
  }, cb);
}

let f = bind((a, b) => a + b, 1, 2);
let g = bind((a, b) => a + b, 1);
let h = bind(g, 2);
console.log(f(), g(2), h());
 
This is amazing.
 
ouch
 
LOL
that kid was flying
 
5:35 PM
@poke that's entertaining. Applying bind with f, [this, ...].
I imagine all of this is hell on the optimizer.
 
I think you think too much about the optimizer.
 
@Retsam not according to our clients
 
@ssube Hey, if worrying about JS optimization is your job, that's great. But I feel like you make an excessive number of comments about optimization in this chat room for questions that aren't about optimization
 
5:43 PM
Why write code you know will be slow? Don't micro-optimizing, but don't dig yourself into holes either.
It's usually easier to fix things before you fuck em up.
We know that closures aren't quick and do terrible things to GC, so overusing them (like my reduce-binding thing) is a bad idea.
 
It's mostly about "what information is most relevant to the person asking the question", and that answer usually doesn't include optimization quirks, in my opinion.
 
I'm of the opinion that you should usually list common gotchas with an answer, and something that can become very slow is a reasonable caveat to include.
 
@ssube Allowing people to make informed decisions is great :)
 
ASR
I want to learn java script these 2 days,can any one give me best tutorial links for java script?
 
@ASR what do you want to do with it? What do you want to learn about it?
 
5:52 PM
does there exist a function in underscore that searches for all keys, even in nested objects?
 
ASR
@ssube for learning jquery
 
@corvid It doesn't look like it: github.com/lodash/lodash/issues/219
 
@ASR jQuery should be one of the last things you learn. It is largely obsolete.
 
^ lol, funniest I've read all day
 
ASR
I know basics, want to learn deeply.
 
5:55 PM
I would argue jquery it's becoming more integral rather than obsolete, it's the underlying technology in more robust mvc frameworks and such now
 
@ssube I guess I'd disagree that performance is usually a "common" gotcha. Given that most JS is client-side, and most of that is IO-bound, not CPU bound
 
@EricLease Welcome to the JavaScript chat! Please review the room pseudo-rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
 
i mean underlying dom selector
 
Oh boy, you say something bad about jQuery and the sharks start circling :P
 
@EricLease that's hardly true. Most of the features jQ used to provide a polyfill for are now standardized and/or included in browsers.
 
5:55 PM
nah, I agree with the sentiment that you should learn that later, maybe not at all if you're working at a higher level, with an angular or something like that
 
@ASR Best tutorial I'm aware of: eloquentjavascript.net
 
now that we have querySelectorAll
 
user2620028
Have I ever mentioned how much i hate IPB. It is preventing me from completing anything as simple as a document.getElementById
 
ASR
@Retsam thank you very much.
 
@ssube - that's true, but jQuery is a lot more than simple DOM traversal, and it's hardly obsolete
 
5:58 PM
@Retsam ah, looks like what I wanted to do was way easier than I thought
_.filter(module, function(key) {
  return _.isObject(key) || _.isFunction(key);
})
 
@adeneo jQuery has animations, which are painfully slow and aren't used often anymore. It has events, which are useful, but a ton of other implementations are available. It has promises, but those are just plain wrong.
 
It doesn't have promises. It has things that vaguely resemble promises. If you squint.
 
broken promises, one might say
 

« first day (1630 days earlier)      last day (3332 days later) »