« first day (2257 days earlier)      last day (2915 days later) » 

02:00
thanks for the help @lix
The interpreter is reaching the end of the file so it's unlikely something inside system.js is causing an issue
well if i put build.js on top it's the one that gets loaded instead
same for anything else
Oh it's a function
It just returns null
Is the same happening when chaning tags to not be self closing?
brb, tried changing that in jade real fast but it wasn't working, was still self closing, going to have to check when i get the dog back inside :)
02:03
I figured it out
it shouldn't return null :o
what was wrong?
cosmic rays
@david I was calling mget instead of mgetAsync
oh
ohhhh
do I need to use ; after a return in node.js?
02:06
you're doing the bluebird promisify thing?
to stop the code
or just return is enough
you can never stop the code...
(you don't NEED a semicolon after return, but you should probably put one there)
if(err){
    console.log('Error while performing the database query:', err);
    return
}else{
    console.log('Query results:', results);
}
in this case do I need it?
No, but put it there anyway
@david Yeah
02:09
:D ok
realizing my workflow is way to freaking long for a simple html change
have you ever had an Handshake inactivity timeout error in node mysql?
I'm surprised you don't need to reference the path those files live in as normally if they are in the same path you'd still need a "/"
it's still relative to the uri they're being served from so it's fine
@buddyp450 welcome to modern jabbascript
02:13
I'm normally a backend dev, it's driving me insane
jspm 0.17 beta broke my prod build last week
don't ask why we're using beta jspm in prod workflows
@lix just fyi, non self closing tags didnt help
going the route now of trying to write my new string to a temp file and serving that file
inb4 /wrists
sorry I could help more, gl @buddyp450
thanks :)
@Loktar @rlemon hands down... most intense workout Ive ever done in my entire life
I was one pushup away from puking it worked me so hard
@SterlingArcher Sounds like the last time I programmed in visual basic
did you catch the killer though
my whole body is shaking right now
02:21
Not much is known about him, though among circle's he's know as *excel
What did you do?
@buddyp450 script tags can't be self-closing in hmtl
<script src="foo.js" /> Not valid.
mine aren't, i think the dev tools are just making it appear that way
<script src="foo.js"></script>
dev tools? or a text editor?
view source in a browser will show you the real text.
if you ran it through an xml processor, it'll do that. you sure XElem projNameMetaElem := XElem("meta") isn't from an xml library?
02:26
@Luggage I think your onto something boss.
no tags can be self closing in html
or your original html is just broken.
some tags can. I think <input> is allowed to.
@david <br />
no, both of those are just void tags, the / is completely ignored
02:28
you may as well leave it off
@david not all tags
if <br /> is valid, that's new to html5
<br> is valid
yea, and html 4.01 <hr /> was invalid
<br /> is valid, but it's not a self closing tag. the / is ignored and it's simply a void tag
02:29
well, whatever. what i said about the script tag is still true
it is true, but the way you worded it made it sound specific to script tags
<link /> can, i think
pretty sure it's not 100% consistent like you say, because html is not only consistent with being inconsistent.
link is a void tag
so you just put <link>
you don't need the /
stupid html
If it's a void tag, you can omit the / yeah.
02:32
html should never have />s in it
there is never a time when you need that
xhtml compatibility
hello i have a question
nice, i have an answer
the only reason people do it is because they wanted to try make the markup work as both html and xhtml
jQuery("#ulid > li:eq(1)").hasClass("selected").addClass("has-dropdown not-click");

this code give me TypeError: jQuery(...).hasClass(...).addClass is not a function
02:33
but they don't put the proper xml stuff in so it's not xml anyway, it's a waste of bytes
or just because it looked right and they forgot html sometimes wont' allow it
it doesn't look right
a.k.a. being wrong
it looks completely wrong
what looks wrong?
02:33
not if you are used to xml and jsx.
<blah /> in html
subjective
no, it's not subjective
self closing tags are not valid html, so they look wrong in html
02:34
@PureRhymerOrganization I'm pretty sure that's because you can't chain on hasClass since it returns a boolean
if you think they look right then you don't know html
@david html is not the only markup language on the web
your mom is subjective.
@phenomnomnominal of course not, what are you trying to say?
SGML can suck my entire bhole
02:35
so how to make it correct? @SterlingArcher
Who still uses SGML and modeling.. honestly
It's dead anyways
if I used lots of markdown and thought #Title looked 'right' that doesn't mean i can put it in html and expect it to create <h1> tags
@PureRhymerOrganization either use an if statement, or alter your selector to search for that css class instead of using hasClass
so i can easily bypass all of my previous issues fairly easily if I knew how to obtain the response header in javascript from my initial serving of my index.html
02:36
no shit, but html(5) allows /> on some tags, so, not quite the same
(react)
@david well I'm mostly trying to say don't be obnoxious.
What do you mean "self closing tags are not valid html"?
response header?
^ aren't self closing tags valid XHTML?
02:37
they are
yes response header, instead of trying to append it to my head as a meta tag
Are they defined in the html5 spec?
Sounds valid to me
@Luggage it 'allows' it by completely ignoring it
02:38
As "void elements"
@buddyp450 you are backwards. you can't modify a response header from JS client side but you CAN insert a tag in the <head>
I didn't know they had a term besides self closing. TIL
@SterlingArcher they're not defined in the html5 spec
the only time they're referenced is saying that they're ignored
to handle people who think they're writing xml
Like semicolons in JS.
02:39
@SterlingArcher void tags are an SGML (and so also an HTML) thing, self closing tags are an XML thing
And don't use the wrong term lest you want this speech again.
i don't want to modify the response header @Luggage i want to read it
well, don't know hwo to do that for the page request.
same :(
02:40
you confirmed your code was converting to xml?
maybe for requests other than the very first one sure - but not for index
@david iunno, im reading the spec and they're in there
I just Ctrl + Ffed the spec for "self-closing".
They have been mentioned 32 times.
And "void elements", only 7 times.
ahh "it's not possible without making a request js side"
answers my question
Relevant: Section 8.2.4.10
02:43
3 mins ago, by Sterling Archer
https://www.w3.org/TR/html5/syntax.html#void-elements
also that
Apparently, foreign elements can be "self-closed" too.
@littlepootis void elements
In addition to the void elements.
I was playing @david since he combat logged.
@SterlingArcher tnx bro
02:46
you guys can't just ctrl-f and count occurrences, you need to actually read the spec
I did.
Just now. It says this conversation is shallow and pedantic
those things you're finding are all referencing foreign tags, for compatibility with including xml namespaces
!!afk protein
02:46
You obviously didn't, look at 8.1.2.1 Start tags
"Then, if the element is one of the void elements, or if the element is a foreign element, then there may be a single "/" (U+002F) character. This character has no effect on void elements, but on foreign elements it marks the start tag as self-closing."
It has no effect, unless you're using a foreign element
The point about "self closing tags" being a valid term has been proven. We already agreed with you that you don't need /> and it's redundant, where allowed.
which you're not if you're writing html
i never said it wasn't a valid term?
it's an XML term
it's used when dealing with xml
which is what this spec is doing... it's specifying how to interop with xml...
(at least in the places that mention self-closing tags)
ok, so?
What exactly do I have to do to end this? do I have to promise to never use the term 'self-closing'?
No, you're welcome to, I don't have any issue with you
it was the other guys who were saying they were valid html
the spec says it's allowed, so it is.
02:51
the spec says it can be there, and that it has no effect, and only on void elements
right, that's what "allowed" means.
note how it didn't say "required"
you're confusing syntax with implementation
No I 'm not.
you are 'allowed' to put the syntax for them
but it doesn't do anything
you aren't 'allowed' to have self closing tags
you're allowed the syntax for them, in places where it makes no difference
ok.. i can have a /> but.. I jsut can't call it a self closing tag.
so we're back to that
02:53
@david so they're valid
how is this difficult for you little pootis
they're not valid, you will NEVER have a self closing tag in html
you can have something that looks like one
because the syntax is ignored for void elements
because you are being a pedantic jerk telling us we can't use a character the spec allows and/or you can't call it 'self-closing'
but it's not actually self closing
whichever of those works in the moment.
so.. back off, please.
... are you being serious?
02:55
@david AND foreign elements.
In HTML5, the meaning of <foo /> depends on the type of element.
- On HTML elements that are designated as void elements, it is allowed, but has no meaning. It is just syntactic sugar for people (and syntax highlighters) that are addicted to XML.
- On other HTML elements, it is an error, but error recovery will cause browsers to treat it as a start tag. This will usually end up with a missing end tag putting subsequent elements as children of it.
- Foreign elements (imported from XML applications such as SVG) treat it as self-closing syntax.
there you go
> it is allowed
but not valid
no, that's followed by: but has no meaning
and if you keep reading, he says it's syntactic sugar, he is talking about the syntax being allowed...
03:04
yea, i never contested that
If you keep reading, he taks about foreign elements.
I am against your instance that I must say "invalid", and I won't
I don't want you to say anything
Foreign elements are self-closed like this --> <math/>
I don't care about what you believe :S
03:05
Not like this --> <math>
I'm just trying to avoid having incorrect information in the chat
It's not about what our opinions are.. on this.
then why did you drag this on for so long? I stated of was saying that html5 "allowed" the anding slah on some elements, and you insisted it was "invalid".
@littlepootis i'm not sure what your point is either... the spec clearly says exactly what you're saying and noone is disputing it
invalid implied it won't parse, or only parses due to error forgivement
not explicitly allowed in the spec, but only for compatibility
see how those two are different?
03:06
No, I never contested anything you said @Luggage, it was someone else saying self closing tags were valid in html, which they're not
that was me.
then you're wrong, and will always be wrong
Wheeeeeeee!
you corrected me that they were called "void elements" but I didn't give a shit. everyone knew what i meant
Yeah, but my dad could beat up your dad.
03:07
He has :(
they aren't called void elements.
void elements can be self-closing
There is a difference between a void element and a self closing tag
as I learned a few minutes ago, they aren't the only ones that can be self-closing
o_O you learned wrong
the spec is wrong?
03:08
because... as you have been saying over and over, foreign elements can also be self closing, and don't have to be void
Isn't that exactly what I just said?
oh, yeah you did, my bad i misread
@SterlingArcher haha just wait until tomorrow
@Loktar SterlingArcher is afk: protein
plyometrics will make you feel terrible, but awesome
tomorrow is probably the worst one honestly
03:13
@Loktar How does it feel like to give birth to a 20 year old?
ask her!
she's dead
punched my way out
was sick of not being able to eat when I wanted
user6820627
03:57
@littlepootis hello! you are my father.
04:10
Hello, related to Node.js, How can I call a function defined in the server from the client?

I have a grid that should be dynamically filled with different posts from a database, I am using a module for pagination and thus would need to make an AJAX request to the server so that it paginates and returns the required information.

Am I overcomplicating things? Kinda seems like it.
@EliecerThoms 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.
@EliecerThoms what is your server like? Do you have express included with endpoints and stuff?
@david Yes! Using express. And not sure what you mean by endpoints, are those the route.get handlers?
I mean, not sure what endpoints are, lol
endpoints usually just means a path you can hit
so like
oh yeah, was thinking of that, but wanted experts' opinion haha
04:15
app.get('/some/endpoint', function (req, res) {
  res.send(callYourFunctionHere());
})
like a POST request to example.com/getpostsfromhere
ah, I see
and then on the client you would call fetch('/some/endpoint'); and it would hit the server, the server will call the function, and return the result
Hey guys :) I'm having a really hard time updating node.js
-bash: /Users/tdiddy/.nvm/versions/node/v5.6.0/bin/npm: No such file or directory
I'm trying to use v7.2 but my computer won't stop trying to use 5.6
@david would fetch be a previously defined function?
@user6582640 is that the error you get when you try to run npm? It looks like you may have a screwed up symlink
04:17
Like jquery's .ajax() ?
doh!
yeah, npm start
@EliecerThoms yes
Thanks @littlepootis and @david
@EliecerThoms fetch is a new function that exists in modern browsers
it's not previously defined, it just works
Where do I go to fix symlinks?
04:19
@user6582640 where did you install 7.2 to?
he's using nvm
aaah, interesting! gon research that up
/usr/something/Cellar (homebrew)
and then I downloaded it from the node website and ran that as well
looks like you were using nvm, and you're now using homebrew
04:20
echo $PATH
type which node nvm
/usr/local/bin/node
will you ever want to use 5.6 again?
if not, just do rm /usr/local/bin/node
and rm /usr/local/bin/npm
04:21
$ echo $PATH

/Users/tdiddy/.nvm/versions/node/v5.6.0/bin:/Users/tdiddy/nodejs-getting-started/2-structured-data/y/google-cloud-sdk/bin:/opt/local/bin:/opt/local/sbin:~/redis-2.8.13/src:/usr/local/bin:/usr/local/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Users/tdiddy/yeoman10/yeoman-custom/cli/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/git/bin:/Library/TeX/texbin
and then re-install 7.2
thank you david!
and little pootis
should I clean my $PATH somehow?
I use n
let us know how it goes
npm install -g n
04:23
nah, your path is fine
@user6582640 remove nvm stuff from .bashrc
Then just n latest
not sure how. emacs .bashrc in $HOME?
actually maybe not, little pootis is right there is some weird nvm stuff in there still
04:25
there wasn't a .bashrc file in $HOME
what shell do you use?
bash?
what's in your .profile?
ok, I did it with textedit instead of emacs (lol)
way easier for me
just deleted the last lines in the .bashrc file and am reinstalling node
Do I have to edit the file again? Node installer says:

Make sure that /usr/local/bin is in your $PATH.
what lines did you remove?
04:29
node is updated!
I didn't save them. No way of knowing
And my react-starter-kit still doesn't work haha
Start a new shell and echo $PATH
$ echo path
path
er
crap sorry
lmao really sorry
$ echo $PATH
/Users/tdiddy/nodejs-getting-started/2-structured-data/y/google-cloud-sdk/bin:/opt/local/bin:/opt/local/sbin:~/redis-2.8.13/src:/usr/local/bin:/usr/local/bin:/Library/Frameworks/Python.framework/Versions/3.4/bin:/Users/tdiddy/yeoman10/yeoman-custom/cli/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/usr/local/git/bin:/Library/TeX/texbin
ah, everything's fine
04:31
w00t!
So how's everyone tonight, anyway?
concerned
Still alive
so it's all good now @user6582640? node --version gives a nice v7.x.x?
yep!
my react starter kit still doesn't npm start, though
04:35
npm --version
which npm
$ npm --version
3.10.10
what does it say when you try to npm start?
is this in another terminal that hasn't been closed and reopened?
/Users/tdiddy/react-starter-december/node_modules/sequelize/lib/dialects/sqlite/connection-manager.js:25
throw new Error('Please install sqlite3 package manually');
npm ERR! Darwin 14.5.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "start"
npm ERR! node v7.2.1
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! @ start: `babel-node tools/run start`
npm ERR! Exit status 1
doh
04:39
have you done npm install?
oh
please install sqlite3 package manually
hahahaha
so I just npm install sqlite3?
-g?
dunno :S
04:39
haha
why do you need sqlite3 for react-starter-kit?
note sure, @littlepootis
@user6582640 without -g.
no don't try with -g
YEAH DON'T
don't
what am i drinking
04:40
oops
hahaha
-g makes it global, which is generally not what you want
thanks @david
when did you start on this?
when did you run npm install?
a day or two ago
i'd try nuking the node_modules folder and doing a fresh npm install
04:41
AHHHH! omg!! it works!
So excited to be running my new framework :D
nuking == deleting
i am going home
This, is my home. My Ellis island
night
glad you could get it working!
haha thanks so much for your help!
you rock as a person for offering it
bye everyone
@KendallFrey heh maybe many people aren't playing but I'm #1 in the world on hardest survival in Zombie Rampage
actually seems kind of crazy you and I are so high in leaderboards
I wonder what the install base is man
/me heads to bed
04:55
1 message moved to Trash can
@EliecerThoms Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq. For posting large code blocks, use a paste site like gist.github.com, hastebin.com, pastie.org or a demo site like jsbin.com
@david hey man, ìn my express server I think I got the endpoint for the posts set up, but now I worry of it being vulnerable to being accessed by any requester. Is the following okay by itself or do I need to do something else?
https://hastebin.com/lemevowaqo.js
Is the POST method even necessary?
05:37
hi all
hi all

« first day (2257 days earlier)      last day (2915 days later) »