« first day (1339 days earlier)      last day (3619 days later) » 

12:00 AM
Yo... Does anyone know if it's possible to detect mouse clicks from the side buttons? like buttons 4 and 5...
 
@aj.esler 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.
 
man! it was 11PM a while ago...
watch some firefly and now it's 2AM
 
12:19 AM
@MemoryLeaks 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.
 
lionel messi !!
 
12:41 AM
@raser 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.
@Alex 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.
@RiverTam 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.
@DanWalmsley 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.
@ChrisFoster 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.
@mxro 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.
 
1:44 AM
@Nikzilla 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.
 
2:01 AM
@MindingData 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.
 
2:42 AM
@SomeKittensUx2666 When are you having babies?
 
in a few years
 
2-3?
 
2-3 babies?
 
approximately. Depends on my career (to both questions)
 
lol
that's a small litter
 
2:47 AM
Yeah, cats have 4-5?
 
Don't badgers also have lots?
 
> Birth is usually in April, or perhaps as late as June at higher altitudes. Usually 2 to 7 young are born. Although the female has 8 teats, litter sizes tend to be small, and a litter size of 3 is common.
 
3 it is
 
How many would constitute an army?
 
2:54 AM
TIL: @BadgerGirl has 8 teats.
 
And you have a spiked penis.
 
!!urban TIL
 
@monners [TIL](http://til.urbanup.com/4190243) T.I.L. (Today I Learned)
Often used as a space saver on websites such as Reddit or DIGG when writing the titles of links to interesting things the submitter has learned that day.
 
!!s/spiked/barbed/
 
@monners That didn't make much sense. Use the !!/help command to learn more.
@monners And you have a barbed penis. (source)
 
2:55 AM
Why thank you
TIL: TIL
if (data.status == 'success') {
    $(document).trigger(etc);
} else {
    // handle error
}
that's some mighty fine error handling ya got there
 
Whoever wrote this file I'm working on
 
@DavidGood 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.
 
else {
    alert('Error: ' + Math.random() * 5);
}
 
3:05 AM
Morning
I have a stupid question
learn.jquery.com/javascript-101/arrays/#sort- <--I can't understand the function thingy in this
// Sorting with comparing function.

function descending( a, b ) {
    return b - a;
}

var myArray = [ 3, 4, 6, 1 ];

myArray.sort( descending ); // [ 6, 4, 3, 1 ]
^What is that?
 
The function is an example of how the .sort() method works. myArray.sort( descending ) is an example of the method in use
 
the function descending takes 2 args, none is given when calling it. Why?
 
.sort calls it
 
It probably defaults to one or the other
 
@Meredith so?
 
3:08 AM
it's the method they use to determine the order of 2 elements
 
Wait, scratch that. Totally wrong
 
if(callback(a, b)){ put_a_before_b();}
 
@monners it is from learn.jquery.com, I got it while I was revising what I studied
 
callback is the function you pass to .sort()
 
The function is an example of a function that you can pass to .sort() to replace the default sort that JavaScript would otherwise perform
 
3:09 AM
> The return value of descending (for this example) is important. If the return value is less than zero, the index of a is before b, and if it is greater than zero it's vice-versa. If the return value is zero, the elements' index is equal.
^Then, can you not pass a negative integer instead?
 
If you pass a negative number in every time
Bad things will happen
 
Why?
I mean this: myArray.sort(-1);
 
If it's negative, a goes before b
So a will always go before b
And it won't sort
 
okay, what is the function descending doing when it is passed to the function sort?
 
Descending returns a negative number if a > b
 
3:13 AM
console.log([ 3, 4, 6, 1 ].sort(-1));
^why does this return 1,3,4,6?
 
Because -1 is a number, not a function
 
but it is doing what we want it to do... or no?
 
It's ignoring it
 
!!> console.log([ 3, 4, 6, 1 ].sort().reverse());
 
okay, no its not doing what we want it to do
 
3:15 AM
@phenomnomnominal "undefined" Logged: [6,4,3,1]
@Hockey 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.
 
!!> console.log([ 3, 4, 6, 1 ].sort(1));
 
@Meredith "TypeError: invalid Array.prototype.sort argument"
 
@phenomnomnominal awesome...
sorry, power off :( bbiab
 
@phenomnomnominal Sure, you helped, but did he/she learn anything?
 
It accepts a function as a parameter and ignores everything else
 
3:17 AM
@monners sometimes i just want people to leave :P
 
Fair call
 
like forever
Eternal September in here
 
@phenomnomnominal hmmm... :(
@Meredith you mean the return value of the function?
what is this __proto__ <--it keeps logging in my console. MDN says it is deprecated and should not be used.
 
!!tell awalgarg google javascript proto deprecation
 
3:31 AM
@CapricaSix exactly. Thats what I read. it keeps popping in chrome console. and it has lots of properties buried in it. Should I care?
 
@AwalGarg Only if you want to be a developer when you grow up
 
@monners I am grown up, :P
^this thing
 
All those first-level methods are the array methods. Very useful to know
 
Why are they logged in the console? Is it chrome's help guide or something?
 
Nope, you're probably logging something in your script
 
3:35 AM
18 mins ago, by Meredith
http://jsfiddle.net/F9cQg/1/
^this is the script
 
Yep, you're logging an array
!!> console.log([1, 2, 3, 4].sort());
 
@monners "ReferenceError: log is not defined"
@monners "undefined" Logged: [1,2,3,4]
 
Well that didn't work
 
ok thanks. you all (except half of @phenomnomnominal) are very much helpful.
2
 
0
Q: One-to-many promises

SomeKittens Ux2666I have a list of customers, and then each customer has a series of tasks to be run. In psudeocode: Get all customers For each customer, get list of tasks For each task, run task However, I want to take advantage of JavaScript's async nature when running these tasks. With promises I can do so...

@BenjaminGruenbaum
 
3:50 AM
0
Q: One-to-many promises

SomeKittens Ux2666I have a list of customers, and then each customer has a series of tasks to be run. In psudeocode: Get all customers For each customer, get list of tasks For each task, run task However, I want to take advantage of JavaScript's async nature when running these tasks. With promises I can do so...

 
4:05 AM
 
don't remind me that Monday is tomorrow
 
Happy Monday!
 
@CrazyChris 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.
 
@SomeKittensUx2666 My Monday's almost over :D
under 3 hours to go
 
40 mins for me :P
Yay timezones
 
4:28 AM
You're the only person in this room that's closer to the future dateline than me :P
 
Yeah buddy, I'm future as
So future I'm learning typescript...
 
I guess there's nothing to look forward to...
 
Why do my messages float in neon tubes? I wish to see them normally...
 
wat
 
bad trip ?
 
4:33 AM
@bhirt 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.
@Simion32 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.
 
Is it possible to detect browser zoom? I want to change the layout of my page at different zoom levels...
 
at 100% -> normal
uh.. ok
well, a few elements of my page go out of screen at high zoom level (500%) is it normal? Should I fix it?
 
yes as in normal or fix it?
 
4:41 AM
Don't use fixed positions and you don't really have to worry about anything
Well you do, but not any huge issues
 
I see a similar issue on Youtube home page at 175% zoom. But they leave it like that. What do you say?
 
4:55 AM
@NReilingh 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.
 
@AwalGarg 500% zoom? I think you'll find almost all websites will break at that level of zoom
 
hmm, se chat looks awful at that
@monners actually, it starts breaking at 175% but the effect is greatly visible only at 500%...
 
@BuddyGorven 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.
 
Can we please have a separate bot for welcoming, I really wish to ignore her... but you guys teach me JS with it.
 
5:09 AM
@AwalGarg What's one use case for that level of zoom?
 
@monners accessibility maybe? IDK, I don't do it. Just thought someone might do it...
 
Mobile users zoom a lot
But not to 500%
 
That's a different kind of zoom
It isn't document zoom, it's viewport zoom
 
Yeah that's what I thought but I was too lazy to research it
 
@AwalGarg Don't worry about it.
 
5:13 AM
alright, thanks...
btw, is it a good idea to build css for your mobile version site entirely from scratch?
 
As opposed to?
 
I don't want to host it on http://m.mysite.com... <--this
 
Do you really need a mobile site?
 
@Meredith yes. and I very much extremely damn fucking need it...
 
!!tell Awal google responsive design
 
I didn't quite get what you are trying to tell me...
> Mobile first, unobtrusive JavaScript, and progressive enhancement
?
 
Design your website so that using a small window won't break it
 
yeah, thats what I am asking. Should I build a new css file from scratch or modify the original one? (for the @media rule...)
 
New
Don't make users load twice as much css
 
@AwalGarg that's typically something you want to have considered before starting your build. Responsive design is very hard to retrofit
 
5:25 AM
-1
Q: AngularJS-Coding of how to get the inner ng ​​declaration?

Tran NhatI have the following code: (function(ng,app){ 'use strict'; //SERVICE NÀY CUNG CẤP THÔNG TIN VỀ ROUTE REQUEST HIỆN HÀNH app.service("requestContext", function (RenderContext) { // ---------------------------------------------- // // ---------------------------------------------- // /...

I have come down with cancer after reading this question
 
0
Q: Turning an array of promises into a Rx.Observable

Benjamin MalleyI have an array of promises that I want to convert into an observable sequence. I have gotten as far as var sequence = Rx.Observable.fromArray(arrayOfPromises) .flatMap(Rx.Observable.fromPromise); However, subscribing to this sequence via sequence.subscribe(processingFunction); does not r...

 
@monners oh, my bad...
 
It'll probably be easier for you at this point to just create a standalone mobile version
Depending on how far along you are
 
there is a constant layout followed in all the pages except 404s and other errors. So essentially, there is a single css file.
If I modify it, all pages get modified...
 
@VedTopkar 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.
 
5:28 AM
as of how far along I am, the css file is done.
 
Do you have an example of what you have so far?
 
@Meredith oops(); <--I can't disclose it, its not mine. Sorry...
I will ask the real owner if I can display it here, if he agrees, I will post a screenshot
Its pretty simple though. a top bar with a few options on either side. a bar below it with search options and all. Then main content div with a sidebar. The sidebar is on right and has an ad placeholder on top... thats all. A footer is there as well.
 
Maybe just hide the sidebar on mobile?
 
It is important, it displays related content. Should I push it down, and make it horizontal?
Related content thing will bring more hits...
so thinks the real owner....
 
Those are design questions.
For your client/designer
 
5:39 AM
yeah, right...
 
@RitamNemira 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.
 
@monners he is no client, he is a friend...
 
What I meant was this isn't really a forum for what do you think will look better type questions
 
i need to add a wait function before calling a ajax function how to do that ???
 
ok... I will refrain from now on :)
 
5:41 AM
i need to add a wait function before calling a ajax function how to do that ??? can anyone help?
 
@shishir123 why would you need to do it. you can use status codes to see if data is ready or not...
I am saying so because I think thats what you are trying to accomplish
I may be wrong
 
actually i want to show some logo before ajax calling
 
well, I've written myself into a corner
 
!!tell shishir mdn setTimeout
 
5:43 AM
@SomeKittensUx2666 NOOOOOOOOOOO
 
setTimeout is what you can use, IMO
 
wait, yes!
haha!
 
I'm totes claiming credit for that revelation
 
awesome, I learnt the function yesterday and today someone appears who has to use it...
 
still hate promises.
and scope
and this
 
5:46 AM
Promises scare me
 
I don't have the freedom I want.
 
@SomeKittensUx2666 Maybe move to Mexico?
 
I want to stop the chain without throwing an error
@monners I'll go hang out in NZ with @phenomnomnominal
 
@SomeKittensUx2666 Oh, geee, thanks
... asshole
 
    "EpisodeID": {
      "$": {
        "$": "17"
      }
    },
These people are retarded. >:(
 
5:49 AM
@BadgerGirl What is it from ?
 
They write Ruby, what did you expect?
 
@SomeKittensUx2666 For real ?
 
^ok, crapped one. but this is the basic thing I was asked to make.
 
You know you can draw rectangles in paint right
 
you were asked to colorize a web page with a black pen ?
 
5:50 AM
hehe
 
That's JSON from some Elastic Search format the guys at DTV have.
And we write Go, not Ruby.
 
@dystroy lol
 
@NathanTomkins 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.
 
Which makes it horribly messy to parse.
 
@BadgerGirl What ? Where do you write Go ? You're luckier than me
 
5:52 AM
At Ooyala, it's the best job ever.
 
@dystroy less "I hate these things" more "I am annoyed by how long my current work is taking due to complications with the following items"
@BadgerGirl speaking of, I'm on the (job) market again.
 
Then apply, links on my facebook page.
The HQs are in MV.
 
@SomeKittensUx2666 Yay.... awwww - come to Australia
We'll pay you in balls of yarn
 
The spider took the seat of monners. Again.
 
@SomeKittens I wanted to tag you when I posted it but then I thought it might get you into trouble.
 
5:55 AM
Brackets Sprint 40 is AWESOME
 
@dystroy How dare you talk about my wife like that
 
@BadgerGirl Is transport a perk?
@BadgerGirl hah, nope
 
@monners I wonder who else would still get the reference :)
 
No idea, but a lot of people who work there live in SF.
 
can I declare an object inside an object? like array in array?
 
5:57 AM
Dunno if I'm qualified for any of those
 
@AwalGarg yes
 
@monners what will the this keyword point to then?
 
OK... I don't have enough time for all the projects on which I am and I still look at the page in which Mozilla asks for contributions...
 
!!> var foo = { bar: { baz: 'Ahoy hoy' } }; console.log(foo.bar.baz);
 
5:59 AM
@monners "undefined" Logged: "Ahoy hoy"
 
@SomeKittensUx2666 I got called from Fog Creek.
But I think I'll pass.
 
@monners this?
 
@BadgerGirl When I see an attractive job offer, it's almost always in SF or in the vicinity...
 
Ooyala is really an awesome place to work.
You should apply :)
 
> A BS/MS or PhD in Computer Science, preferably from a top-tier school
5+ years of front-end engineering experience
I understand some of that can be waived, but not that much
thanks though
 
6:08 AM
Well I got the job, I'm sure you could too.
 
That's what you do?
 
Hey, I just saw the Miaou ad in a SO page ! \o/
 
:D!
 
@SomeKittensUx2666 That CS requirement's gonna knock out a lot of potentially great hires
 
6:14 AM
I don't think it matters as long as you pass the interviews.
 
Sure, it's all about getting to the interviews (totally not being facetious)
 
@monners Including myself
 
how can they tell though
 
Referals always get to the interviews.
 
without interviewing everyone
 
6:18 AM
Yeah, I can do 2+ years
 
Typically the more someone knows about their field, the lower they'll rate their own abilities. Juniors rate themselves higher than seniors on self-evaluations. They don't know what they don't know.
 
I'm not really Senior yet
 
What is the guarantee that someone fulfilling those requirements is better than the one who is not?
 
But that position is in Mexico.
 
we gave launched a kickstarter from our incubator: kickstarter.com/projects/airdog/…
 
6:18 AM
@BadgerGirl ....ah
 
Apply for the 5 year experience one, that's a front end position.
 
@BadgerGirl how do they know I'm a referral candidate?
 
You apply through my link.
 
oh, cool
I'll ping you tomorrow
it's bedtime
 
6:21 AM
Alright :D
 
!!wiki dunning kruger
 
The Dunning–Kruger effect is a cognitive bias manifesting in two principal ways: * Unskilled individuals suffer from illusory superiority, mistakenly rating their ability much higher than is accurate. This bias is attributed to a metacognitive inability of the unskilled to recognize their ineptitude. * Those persons to whom a skill or set of skills come easily may find themselves with weak self-confidence, as they may falsely assume that others have an equivalent understanding. See Impostor syndrome. David Dunning and Justin Kruger of Cornell University conclude, "the miscalibration o...
 
6:43 AM
So... What about people who, during exams, always claim to be so sure they failed, yet in the end get 80%?
Do they suffer from Dunning-Kruger, or are they just attention whores?
 
They lied about how bad they did so they wouldn't make others feel bad
 
Yeah, I'm sure they do it entirely for others to feel better about themselves ;)
 
The worst thing is when you do well on a test and you can't brag about it
Cuz everyone else did bad
 
function $b(id){var e=$g(id+'name'), es=$s(id+'name'), t=$g('bss'+id+'c'), ts=$s('bss'+id+'c');}
^if I initialize this function in another function, will these variables be available in the outer function?
id is of string type
function $g(id){return document.getElementById(id);}
function $s(id){return $g(id).style;}
^these are $g and $s...
 

« first day (1339 days earlier)      last day (3619 days later) »