« first day (1359 days earlier)      last day (3599 days later) » 

8:00 PM
@TheWobbuffet if it would one or the other, it wouldn't be a paradox. That's reductio ad absurdum.
 
"reductio ad absurdum"?
Ok I searched it in google
I still think @Zirak is a black hat hacker.
 
the point is to handle each result separately, and not all of them at the end
 
This is a list of paradoxes, grouped thematically. The grouping is approximate, as paradoxes may fit into more than one category. Because of varying definitions of the term paradox, some of the following are not considered to be paradoxes by everyone. This list collects only scenarios that have been called a paradox by at least one source and have their own article. Although considered paradoxes, some of these are based on fallacious reasoning, or incomplete/faulty analysis. Informally, the term is often used to describe a counter-intuitive result. Logic * Barbershop paradox: The supposi...
 
@SecondRikudo and bluebird provides an abstraction for this kind of run pastie.margaine.com/5255eeb7-60fd-4b65-9088-562dfe3773a4
I should add a "fork" button to my pastie
 
8:02 PM
@Zirak 1+1===2
 
@FlorianMargaine Wouldn't that be sequential?
 
@SecondRikudo nope, Promise.each would be sequential, not Promise.map
 
Gotcha :D
 
@SecondRikudo run this a couple of times in your console, you'll see for yourself: pastie.margaine.com/774cad1b-a1ac-4f57-9732-6dcd389224b6
(spoiler: I got that)
 
@TheWobbuffet the liar paradox is not really a paradox though
 
8:11 PM
@BenjaminGruenbaum new question: when not to use Promise.coroutine? In this case, it's nicer than then, isn't it?
 
@FlorianMargaine when you don't want to use experimental features. Also, there is a error handling issue (ES6 has no nice predicate or typed catches)
 
@SecondRikudo replace Promise.map with Promise.each and the order is always the same
@BenjaminGruenbaum bluebird provides typed catches
but, let's say, in the future, coroutines will just be the way to go right?
 
In short, do not use it if you'll deploy the code. Also, ponder a moment on how doing a generator of promises is like do notation is haskell :D
@FlorianMargaine yes, but in generators you try{ } catch(e){
 
@FlorianMargaine ES7 adds those 9 lines of code itself. In ES7 you have async methods, you use await instead of yield.
 
8:13 PM
@BenjaminGruenbaum I don't know haskell enough
 
Ah, sorry then
 
@BenjaminGruenbaum those 9 lines of code = Promise.coroutine?
 
No - I meant that native async/await over native functions and generators I posted
 
simple example?
 
8:16 PM
and in es7?
 
async function foo(){
    await delay(3000);
}
 
Promise.when(itsTime).then(function()
   console.log( "Happy Birthday Mr Bluebird (@Esailija)" );
});
10
 
It's petka's birthday?
 
8:18 PM
Tomorrow
 
@AbhishekHingnikar that's not how you write Esailija :P
 
How can you tell?
Oh, yeah
FB
 
We have a list of everyone's birthdays
 
exactly :P
 
He deserves better than that shitty pseudo-code
 
8:19 PM
:'( :'(
 
@AbhishekHingnikar Bluebird doesn't have a when method :D
 
@BenjaminGruenbaum that is WHY i did it that way -_-
remember me asking about it ?
 
@AbhishekHingnikar :'(
 
I don't remember every conversation
 
hello, I need help with the following: jsbin.com/dabayuxu/2/edit
 
8:20 PM
noob
 
@Dolores 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.
 
true that.
 
the result should be 2 links
but I don't have errors or anything showing up in the output view
 
I really hate working in Angular at times ...... right now because now there are 3 promise libraries, jQuery's , $q, bluebird -_-
 
@AbhishekHingnikar You can swap $q our for Bluebird though
 
8:22 PM
probably i can get rid of jQuery too :-), idk why it is here but when i remove it it breaks
 
It will easily assimilate $q promises for you since those are A+ and jQuery's promises too because it does that.
 
@Dolores Why would there be any output? You're not calling any of your functions.
 
5
Q: How do I use Bluebird with Angular?

Benjamin GruenbaumI tried using Angular with Bluebird promises: HTML: <body ng-app="HelloApp"> <div ng-controller="HomeController">{{name}} {{also}}</div> </body> JS: // javascript var app = angular.module('HelloApp', []); app.controller("HomeController", function ($scope) { var p = Promise.delay(100...

 
trackDigests(app);
should go in app.run, no ?
 
No, just after you define app
 
8:23 PM
oki :D thankx
 
It does a .run itself
 
what's a digest?
 
Zirak: the first function should run the second function
 
@Dolores And what runs the first function?
 
@FlorianMargaine Angular does two way data binding (text you change in the DOM gets updated into a JS variable immediately, values you update in JS get updated in the DOM immediately). A digest is the process in Angular that does that - it digests all the watchers (that looks for changes) until they're done changing each other.
 
8:26 PM
oh, k
so you wanted bluebird promises to trigger the data bindings
 
Yeah, to notify the library that something has happened
 
urm, I'm not sure what he means by message passing: reddit.com/r/learnprogramming/comments/29yzlm/eli5_coroutines/…
pub/sub systems? That's just events
 
I have no idea what he is saying either
 
Then ask him it is.
 
@Dolores What's $? Where is it defined? You haven't included any external libraries.
 
I clicked on the menu link to include jquery 1.9
 
Can you please explain this to me?
var fSqlClient = pg.connectAsync(connectionString).spread(function(client, done) {
    client.close = done;
    return client;
});
 
In this case, pg.connectAsync would need to return an array of promises, right?
 
8:37 PM
@SecondRikudo no, a single promise, but the returned value is an array
 
@FlorianMargaine I'm just reading the example on bluebird's man page.
@FlorianMargaine So... a promise for an array?
 
so basically I wrote a weather application that displays the weather by parsing a json file from open weather map. Now I want to parse a second json file, so I added another value to the function that sends urls to the function that gets the json data with jsonp
 
a simpler example:

Promise.resolve([1, 2]).spread(function(nb1, nb2) {
});
 
@SecondRikudo .spread destructures arguments. It's like .apply. It turns [1,2,3] into arguments 1 2 and 3 instead of a single argument with params.
 
@BenjaminGruenbaum So, a promise for an array?
With two elements in it in this case?
 
8:38 PM
anyone know of a good js addon for quickly rendering a schedule? Think d3js or highcharts will do the job all the same?
 
@SecondRikudo yes
 
Okay, so I'm guessing client is the actual client, what's done in this case? XD
 
look up postgresql's basic pg.connect
here is the normal API:

pg.connect(function(client, done) {
});
 
Ah, I see
I'll have a look in their API manual then. Thanks
 
@SecondRikudo look at how the API does .disposer and .using for connections - it closes and handles them better IMO.
You shouldn't call .close yourself, it should close itself when the promise chain is done.
 
8:41 PM
@BenjaminGruenbaum did you even look at that? :P
 
thats the weather app, I have the additional code in comments
 
it uses geolocation to look up your local weather
I want to show the current weather, and the daily forcast
 
good night people
 
Is there anyone here who knows anything about developing (or already developed and available for purchase) group video chatrooms that would work in tablets or phones?
 
8:44 PM
@Mandiana 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 that a bot?
 
!!tel Mandiana No, I'm not. Carry on.
 
@Mandiana No, I'm not. Carry on.
 
@Mandiana Google Hangouts?
 
Google Hangouts? ARe you saying that's where I'd be able to find someone? I'
 
8:47 PM
@Mandiana No, Google Hangouts offers a group video chatroom that works with tablets and phones...
 
ve been searching for days on Google search and posted a StackOverflow question last night (with no responses).
 
(And it's free)
 
Oh, no I have a dating site. I need one that will integrate with our site.
We have a Flash chatroom that doesn't work in iPads, phones, etc.
 
jsbin.com/dabayuxu/8/edit So jquery 1.9 is being loaded, and the "urls" function gets called on document ready, but there is no output, and no error messages :/
 
This week we discovered our competitor has a chat where iPad users can view others' cams. I can't figure out how they're doing it.
I would love to pay a developer or buy one that's already been developed, but can't find one and again don't know how they're doing it.
There are a bunch of chats out there that claim to work on phones, but none of their demos actually work.
 
Thank you.. so this is WebRTC? I've been trying to find a working WebRTC demo (to make sure we're proceeding in the correct direction) without success.
EasyRTC, TokBox, nothing I've found actually works on a mobile device
 
Miaou video conversations work with webrtc
(afk)
 
Anybody else with a Nexus or Android Chrome / Beta
 
@Mandiana That's a good place to start
There's a video chat there that you can check out, and it's open source.
 
thank you ... testing on mobile now
 
9:01 PM
@Mandiana I have been working on WebRTC since a long time. there are lots of demo on simpl.info
and talky.io < so far the most robust platform with RTC .. sorry dystroy :-)
also if you are interested in the data channel look out work by @raynos on github
he ended up writing a discovery network that helps serverless stuff synchronize
 
hmm.. I'm not seeing video in miaou?
 
@Dolores you do get error messages
and they outline your spelling mistake
forcast_url !== forecast_url
 
thank you, checking those out now @AbhishekHingnikar
 
I have like the uberdumbest problem ever
 
9:15 PM
526b5583.ngrok.com/#/camera <- should work on computers with a web-cam & chrome-beta androids @rlemon test it man :D
 
@AbhishekHingnikar have you created something with live streaming video that works on mobile? talky.io isn't working on mobile when I tried testing it and it doesn't seem like simpl.info is working on mobile either.. for example, I tried: simpl.info/rtcpeerconnection and nothing happened
ok testing that one
 
@Mandiana talky works fine for me
but i have latest chrome & firefox beta
 
talky works for you on a phone?
Are you saying you've downloaded a chrome browser on your phone?
It works for me in desktop, but I couldn't join the chat created on my desktop with my phone
 
well I didn't need to download it, It came as default stock browser for android 4.4
 
ok.. yes I see I have chrome.. let me try that way
you're right!
 
9:20 PM
obv.
 
oh wow! I was going crazy trying to find something.. you made my day... let me test in ipad
 
cause the stock android browser won't support WebRTC
and iPad will again make you sad :-(, iPad chrome != real Chrome
 
:( is there anything that will make me happy? lol
 
yes... the spec
you can implement it yourself
// just kidding
you can use Ludei's Chromium Webview that will cover all android 4+
and there is an iOS package
that takes google's rtc implementation and binds it for UiWebView apps
not sure of the performance
also probably you will find an implementation in Object. C
 
So, have you developed anything like this before? Are you available for hire?
 
9:25 PM
@Mandiana I have, but sorry am a lil bit too occupied atm
I can help you though :-) feel free to ping.
Infact am working on something webrtc savvy atm
 
Ok, thanks so much for what you've shared with me so far. Very helpful!
lol
 
Hey - is this a legit urinary statement?

var == null ? alert ("null var: error"); : alert ("it is set");
5
*unary fml
 
var == ?
 
var is taken from a MySQL table. I want to check if it is null by a unary statement
 
9:31 PM
alert(var something == null ? 'null something: error' : 'it is set');
 
thankyou
 
hello world
 
@BDillan lol urinary statement
Hmm, a link only links somewhere if you click it, did you try clicking it with your mouse? (Hold your computer mouse firmly, move it with your hand muscles until the pointer on the screen is on top of the "continue" text in your internet web browser and then firmly tap your index finger on the left mouse button) — Benjamin Gruenbaum 1 min ago
 
9:58 PM
@rlemon thanks, that really helped me out :D
 
user652649
@BDillan no that is a very perfect urinary statement xD
 
@AbhishekHingnikar That's awesome
 
user652649
@phenomnomnominal you meant without "var" ?
 
user652649
that should throw an error
 
@BenjaminGruenbaum And the daily prize for Most Patronising Response goes to...
 
10:03 PM
fwiw I was just trying to joke with him - I have no idea what he's asking :D
 
!!urban fwiw
 
@monners FWIW "For what it's worth."
 
@BenjaminGruenbaum fwiw I was just trying to joke with you :P
 
10:33 PM
@Wesabi what?
 
user652649
1 hour ago, by phenomnomnominal
alert(var something == null ? 'null something: error' : 'it is set');
 
user652649
var something == null is wrong :P
 
@Wesabi it sure is, my bad
var == null is also wrong, my pre-coffee'd brain tried to fix it :P
 
user652649
:D
 
10:56 PM
in CSS, how does one make a div which positions itself "over" other divs without getting in the way?
 
@Crow position: absolute;
 
awh lame. but now it's the wrong width
 
@Crow Put together a jsfiddle.com
 
I just got lazy and did z-index: 10;
 
@Crow ...?
which does absolutely nothing...
 
11:08 PM
isn't it what I want if I want it to appear over all the elements?
 
@Crow Yes?
 
yeah, I'm just trying to have an alert show up over everything... actually do bootstrap's alerts already do that? I just don't want it to reposition anything
 
@Crow I told you position absolute.
 
11:31 PM
okay, here's a jsfiddle of what I mean jsfiddle.net/N2Htu/1
 
god, people put so much effort into SO answers
 
ooo that's what I want except for the width should be the same size... just width: 100%?
 
@Crow Yeah
 
sweet, thank you for the help
 
@Crow No worries, feel free to upvote one of my answers
 

« first day (1359 days earlier)      last day (3599 days later) »