« first day (2174 days earlier)      last day (2768 days later) » 

3:01 PM
omg brilliant
 
how did she get the ccv or w/e
 
@rlemon She get half the card in a pic, the other half she can get other ways
 
@BenjaminGruenbaum nice talk. I did feel you moved a bit fast in the middle and the Rx.JS autocomplete SILL looked a lot nicer to me, but I still came away wanting to turn on AsyncIterarors.
 
Bit of a beginner question but couldn't find the required answer on the site.
how do I find the id of an element when I know the row id and the class of the element?
 
"row id" isn't a thing. Do you mean the position of <tr> inside a <tbody>?
 
3:09 PM
@Luggage yes, both the duration and language changed in the last minute - thanks :)
No one here liked it :P
 
@Luggage Sorry for the improper wording, It is the id of the <tr> in which my element is a part of
 
ohh, so: <tr id="i-know-this-id"> <td>...</td> <td class="thisClass"> </td> </tr> ?
 
yes, I need the id of the element in the class "thisclass"
 
@KendallFrey lol
 
3:12 PM
Would you know how to style that element?
 
Y'all have probably got this question 100 times but... how do you apply an animation to an element after some property changes in React? Say open changed or something
 
1. Get a reference to the element. Use a css selector, as a string, in document.querySelector()
2. `id` is a property on the element. Just read it like normal property.
 
hi
 
Only my wife can call me Lu.
 
3:16 PM
@Luggage I need it to make it hidden. So yeah let me check out queryselector
 
Plot twist: It's your wife
 
if it's a <td>, I think you'll want to use visibility: hidden; instead of display: none; to hide it. But let's focus on getting a reference to the element first.
 
yeah, since it is a table and there are multiple rows I can not use the class alone. Need to get the row along with the element
 
I'm passing an iso string from server side to client. Then trying to convert that to a Date format to suit JS on the client.
Doesn't like the format of the iso string coming from server though
 
/Date(14516064000000)/ is not an iso string. It's a date string as output by some .NET serializer
I think the number inside is something standard "e.g. seconds since 1970", and you can use that, or moment.js will parse it.
 
3:20 PM
ok maybe using moment is easier in this case
 
moment.js will parse it, yes, but i's a heavy dependency for that one task
now.. i like moment.js and use it all over the place.. so..
otherwise, jsut search for "parse .net date in JS" and you'll likely fine some solutions with a few lines of code.
188
Q: Converting .NET DateTime to JSON

user76071 Possible Duplicate: How to format a JSON date? My webs service is returning a DateTime to a jQuery call. The service returns the data in this format: /Date(1245398693390)/ How can I convert this into a JavaScript-friendly date?

That accepted answer has everything you need to parse it.
 
thanks guys
@Luggage
 
send donations to luggage@so-js-chat-room.fake. I haven't eaten in a week.
 
Holla people
I've got some questions on graph theory if anyone can help/
 
3:31 PM
LOL
 
That's funny, but who takes verbatim notes?
 
PEOPLE WHO CARE ABOUT LEARNING
 
especially when you obviously can just take a picture.
 
!!afk CARING ABOUT LEARNING
 
I care about learning too
about friggin graphs
can anyone help me
I feel like a damsel in distress it's emascualting
lol
 
3:33 PM
!!welcome NicholasKyriakides
 
@NicholasKyriakides Welcome to the JavaScript chat! Please review the room 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.
 
oh kay thanks
 
We can't tell if we can help until you ask.
 
So I've got a list of nodes
I'd like to filter a list so that I'd get only the nodes that have a connection, either direct or indirect with a candidate
Example
var candidate = 1;
var data = [
  { source: 1, target: 2 }, // is connected with 1
  { source: 2, target: 3 }, // is connected with 1
  { source: 6, target: 9 }, // no connection
  { source: 12, target: 15 }, // no connection
  { source: 3, target: 2 }, // is connected with 1
  { source: 5, target: 3 }, // is connected with 1
]
Discard all the nodes that don't have a aconnection with 1
1
I'm pretty sure that doing a BFS is on the right track but any attemps to do BFS to solve this fail on my end
 
brute-force search, my favourite
 
3:36 PM
I'm terrible at graph traversals
 
me too, i assume.
 
is there ever more than one target?
 
so these aren't all one-way?
 
no
makes a difference?
 
yes
 
3:38 PM
trying to close a popup window with jquery, the anchor tag is set to href="#" but when I open the popup, it is replaced with the url I opened.
 
{ source: 2, target: 3 }, { source: 3, target: 2 },
 
Yeah
They can be like that I guess
bi-directional
 
sounds like a fun lunch-time problem today
 
I sure hope so!!
What's your thoughts??
I have nil idea about graphs and I'm pretty sure I'll stumble over them again pretty soon
 
youtube.com/watch?v=csInNn6pfT4 So they say there's a cock and balls on the moon...
 
3:41 PM
@NicholasKyriakides BFS would work, as long as you mark as seen, so you dont loop infinitely
 
Ayee that makes sense
yeah something like that
@Luggage
So... basically let's say for example that the candidate = 6
I'd like to keep only 6,9
meaning only that graph group
 
man I love graphviz
 
I'd make it a bit more complicated
Let's say the candidate = 1
I'd like to keep only the first graph group from your graphviz visualization
Meaning 1,2,3,5
 
I am trying to get the value of a child element with a particular class.
Am i missing something?

var target = event.target.id;
var rowId = $('#' + target).closest("tr").prop("id");
var val = $('#' + rowId).children('.value').attr('id');
I am getting an undefined value for val
 
3:46 PM
I have no advice. I could come up with a solution looping over it multiple times, but it'd probably be inefficient. I have no education and no experience with this, specifically
 
Yeah me neither
I've studied MIS and this is just foreign to mee for gods sake
 
If you come back after lunch I'll have a solution, but it might not be great :P
 
basically, just keep a separate list of "included" and stop looping once you make a complete pass without adding anything. That's my brute force approach.
 
I don't really care
 
@NicholasKyriakides: I d do it in two step, first, start from every `source: 1`, mark every target as to keep. Recursive for evy of thoses target to find the childs.
Once done, do evey source not marked as connected or rejected, and try to link to nodes of whose state I know of
 
3:47 PM
the dataset is <50,000
@BenCraig If you can come up with a solution is there any way you can also explain it with some comments
??
 
@NicholasKyriakides Can there be more than one target?
of course
 
that makes life easier
 
You mean like this/
{ source: 1, target: 2,3 },
 
@The_Outsider then are you getting anything from $('#' + target).closest("tr") ? if not, are you getting anything from $('#' + target)?
 
3:49 PM
essentially, though thats not valid json
 
yeah you mean target could be an array
then no
 
I'm streaming: twitch.tv/shmiddty
 
@Luggage The target and rowId are getting the right values. it is only in the last staement that I am getting undefined
 
@The_Outsider oops, you said val was undefined. Same thing. Break down that line and figure out where it's going wrong.
 
@BenCraig but a node can be targetted by many others
 
3:50 PM
@NicholasKyriakides thats fine
 
@Shmiddty before i click that link.. WHAT are you streaming?
 
Eternal
 
^
 
@BenCraig Cool - I can stick around as long as you ask me too :)
 
woohoo
Kernel Recipes is super cool
so many kernel maintainers
 
3:53 PM
wuz that?
 
a conference in Paris, right now
there are <70 attendees + the speakers, so it's pretty small
 
@NicholasKyriakides s'all good - gonna go get some food then have some fun
 
Um, should i stick around here? I'll go grab some food as well
 
at some point the guys in front of me were doing grep <my name> MAINTAINERS | wc -l
(where <my name> was the name of said-guys in front of me)
 
did that make your pants tight?
because it should.
 
3:55 PM
rather loose
it went loose -> tight -> loose
anyway
it's fun :)
 
@NicholasKyriakides: Was thinking, maybe you should try a algorithm like A*, and traverse from source or target, so that the "one directional" link is not a problem
 
The problem is this
I have no graph traversal experience of any sort
and I hate to ask for code samples cause it makes me look like a vampire
Do you have a code sample doing A* in JS
 

« first day (2174 days earlier)      last day (2768 days later) »