« first day (1907 days earlier)      last day (3048 days later) » 

7:00 PM
but is zombie related
 
@SterlingArcher it's fun right?
 
"use strict";
const express = require('express');
const app = express();
const fs = require("fs");

app.set("view engine", "ejs")
	.use(express.static(__dirname+"/public"));

app.get('/', (req, res) => res.render('index.ejs'));

const server = app.listen(8080, () => {
	let port = server.address().port;
	console.log(`SourceUndead has risen from the dead on port ${port}`);
});
 
anybody who wishes to test ... ping me :-)
 
Pretty node code <3
 
@Loktar shouldn't you unlock it and send them the transfer code?
 
7:00 PM
@SterlingArcher if you use babel you can use es6 module syntax
which is even nicer
 
so they can take it right over
 
@ssube I will once the escrow site says to
 
    import fs from 'fs';
    import {foo, bar} from './utils.js';
 
I think its waiting on something currently?
idk have never done this before
 
ah
 
7:01 PM
Maybe lol
 
@SterlingArcher :->
 
@SterlingArcher check out the final es6 module syntax
 
@Abhishrek ping?
 
you might just like it
 
@SterlingArcher pong
we were gonna meet on sunday xD
 
7:01 PM
:D
 
boy that didn't turn out
 
Yeah that fell through. I had food poisoning
 
import { bar, baz }, Foo from 'foo'
 
Oh, while were on that topic, sunday was the closest I've ever come to shitting myself
 
import { bar as turds } from 'foo';
 
7:02 PM
@SterlingArcher lmfao
 
god, module syntax is so much better.
 
so are you free today ?
 
I wish a single engine supported them :(
 
import {default as Foo, bar as bards} from 'foo';
 
@rlemon what's wrong with require? D:
 
7:03 PM
@rlemon webpack bro
@SterlingArcher a) everything
 
@SterlingArcher way less lines mate
 
b) the rest of the things
 
@ssube not the issue
 
@Abhishrek lets do friday. Worknights are tricky for me :(
 
I wish a single engine supported them
 
7:03 PM
import {foo, bar, baz} from 'foobarbaz.js'
 
@rlemon engine?
 
is so much better than the require alternative
 
v8/spidermonkey/etc
no one supports es6 modules yet
 
oh
 
@SterlingArcher as you say bro.
 
7:03 PM
yeah, the system stuff isn't well defined yet :(
 
I had a java dev friend of mine look at some ES6 code, and he just said, "Wow, that's a lot of imports"
 
I SAID GOOD DAY LINDA
@ndugger ... the irony melted my foreskin
 
I'm using Typescript which lets me use the import - from syntax, which is nice.
 
Don't call me Linda, Shirley
 
@rlemon spidermonkey's latest nightly has es6 modules and a hook to define a requirer
 
7:04 PM
lol
 
I don't mind running babel. babel-node makes it painless
 
Hello, can someone tell me why does it tell me that target.appendChild is not a function?jsfiddle.net/4g99jfcj/5
 
$ babel-node app.js
never have to worry
write all my shit in es6
 
@Poteito because target isn't a thing
 
I'm scared if I start using all these things like EJS and babel I won't have a single idea what I'll be doing
 
7:04 PM
I'm still on Babel 5, since when I tried v6, decorators were broken in it. Not sure if they fixed it yet
 
@SterlingArcher don't think about babel
think about es6
 
so hot right now
 
babel should be something that you can replace with any compiler
 
you're using templates to make your HTML read better and ES6 to make your code read better
 
if your code is valid es6
so don't get caught up on the compiler step, just write the es6
 
7:06 PM
you don't need to understand the details of how code goes through the parser and AST and whatnot
 
Yeah, as long as you don't use the experimental stuff.
 
and yea, templates are just WAY better than churning out copy pasted HTML on every file
 
Well I am ES6'in
 
pick up the details of how your tools work later
 
so use es6 modules
require is a node thing
 
7:06 PM
Yeah, even if I don't do actual templating, EJS did just make serving pages nicer
 
also use blackbeard, because it's super kawai desu chan
 
Single URL game thankfully, but that means there will be lots of websocket updates to little datas
 
no about page?
no login pages?
no FAQ?
 
There will be 3 pages -- index, createAccount, and login
 
you'll (likely) end up with a handful of pages, all requiring a footer. boom, ejs pays off.
 
7:08 PM
Maybe a FAQ eventually
This is true
 
I used to love ejs, until they took out some really important features...
 
So, a big thing I used angular for, was being able to update html element text on the fly, from a websocket call. Can I do the same with EJS?
 
user1596138
Ugh being off work for 2 weeks makes each work day feel like 2 weeks
 
How does an "ejs" variable map to a node variable?
 
user1596138
2 weeks in which you need to do 4 weeks of stuff
 
7:09 PM
@SterlingArcher ejs runs on the server
nothing changes there
 
user1596138
But you only get Monday done
 
it isn't magical.
 
So there's no interpolation
 
Man, it's been a while since I had these same exact learning curves. Learning Node was so much fun; it made me feel really smart, lol
 
BUT, you can do stuff like res.render('userProfile', { user: userObject }) then on the page access it under the variable user, like <h1>Hello <%= user.username %>!</h1> @SterlingArcher
 
7:10 PM
@ndugger : that's how you're preparing yourself for a party ---^ ?
 
yes
 
user1596138
Ignore the caption
 
user1596138
 
@rlemon mm, I don't think that will be ideal, since the index (main map) page will only render once
 
user1596138
This pic is just so good hahaha
 
7:10 PM
@ssube Ok but how does getElementsByName work ? does it require more then 1?
 
@KarelG I also charge that much per ride
 
So I'll have to attach document objects to socket responses
 
@SterlingArcher yea I'm just showing you what ejs can do for you
 
And make like an element object
 
Hello
0
Q: Include specific folder to zip using gulp.js, preserver folder tree

gskemaThese are the files: themes/ theme1/ style.css ... theme2/ style.css ... debug.tpl ... config.xml ... ... denotes other files. I want to add these files to .zip archive (paths must be preserved): themes/ theme1/ style.css ... config.xml Before I used to hav...

 
7:12 PM
I also want to attach getter and setter variables to my player class, that are directly mapped to the database, so when Node modifies a player object, it updates the database in turn
(is that smart?)
It feels smart
 
oh dear no
 
@SterlingArcher sounds kinda like how passport.js works with deserializeUser
but not really
but kinda
 
So it's a good idea?
 
not really
 
you should just make them regular methods that you define as async, otherwise you'll have asyncronous getters, and I have no idea what you're gonna do with that.
 
7:13 PM
I'd make a function called deserializeUser and make that update the db or something
then call it when needed
 
const foo = await something.foo
 
@Poteito it gives you all elements with attribute name=... in the document. Please check mdn for reference
!!tell Poteito mdn getElementsByName
 
Soooo like player.alterHealth(-45); will mutate the property, then player.save() will update the DB?
 
!!afk creating a visible mass of condensed water vapor floating in the atmosphere, typically high above the ground, but in this case not so much.
 
7:15 PM
Yeah I'm going to vape as well. My head is buzzing. Ping me if you have good ideas on player object to database value mapping
 
@SterlingArcher Do it the normal way. Define a save or commit method. You want to batch up small changes, otherwise you'll hammer (and knock down) your database.
0
Q: Java Webdriver. Drupal admin menu redirecting all page element clicks to itself

al_loI am trying to create a QA test for Drupal to use to be sure users can create content. In the test, I ask it to log in as me. Once logged in, I get the option to create content from a short cut in the admin bar labeled "Add Content". On the following page, I select the content type. Problem is ...

> Code fount here: Cant get java tests to click on different divs.Browser gets confused. Used Selenium IDE to export Java/Junit4/Web Driver.
if your code is from and/or in the other question, how are you not a dupe?
 
@ssube so basically a player.save() method that I call after each alteration?
Isn't that the same thing?
 
@SterlingArcher that you can call after some alterations
let's say you have to take away health and add XP. Why save twice?
 
ahhh so a method to call at the end of a function call
 
maybe
you won't know how often you need to commit records until you know what you're doing with them and how
 
7:23 PM
@KarelG lol it creates an array that's why it didn't work
 
Well, assume every button or action you take will change something. like, you click move west, youre changing your coordinates. That will require a save
But I see what you mean
 
make it a separate method, call it frequently now, but you'll have to start batching later
 
Fuck you James
 
hahaha that YT clip
i thought "no ..."
clicked it
ok ...
 
crl
7:27 PM
little Fermat or the big one?
 
medium fermat. Small fermat can't hold enough, big fermat runs out of memory.
 
@KendallFrey I don't get it
 
crl
can someone subtitle it? non-native speaker
"Breathless speaking it was too short to contain" that's all I get
 
"which this video is too short to contain"
 
> I have a truly marvelous demonstration of Fermat's Last Theorem which this video is too short to contain
 
crl
7:32 PM
ah ok, that's Fermat's words ^
 
oh god blur is 6 years old
 
So C++ guy doing JS after 5 years away. Are constructor functions in vogue still or is that now an anti pattern and I should try to write in a more functional style.
 
crl
now JS has become Java, everything is different, nah jk
 
@rerun use classes now
 
Find out how attractive you are: faces.ethz.ch
 
7:42 PM
merge conflicts suck
 
how can i after i submit a form keep checkbox check ?all the search i done doesnt help
 
how are you submitting the form?
 
@KendallFrey thats es 6 i'm assuming
 
submit button
 
you'll have to somehow pass the fact that it should be checked in the response from the server. Not js related.
 
7:43 PM
@rerun JS is getting more like C++ and other, more real languages
 
@rerun with compilers like babel you can use es6 in all places that support es5
 
do you guys like my new avatar?
 
crl
fuck it's more precise than howold.net
 
no
 
yes
 
7:43 PM
maybe
 
good
 
@rlemon you like that over typescript
 
@crl 3 years off for me
 
crl
of course we do
 
@rerun never used typescript. babel isn't a 'new language', it just compiles valid es6 to es5
if you want something you can seamlessly remove later, babel is it
 
7:45 PM
@rlemon sourceundead.com she working <3
 
nice
 
I hate that there's so much confusion around Babel; a lot of the people that come in here to complain about how stupid it is don't understand that it's not a new language, lol
 
it is like a polyfill, something that can and should be removed when support fully lands.
 
@Cereal Jesus is not "Godlike".
clearly fake
 
I'm trying to create a new Element by using createTextNode with an array But it keep overwriting. Is there an alternative ?
 
7:50 PM
@SterlingArcher I have a question
 
@Poteito what does your code look like
 
crl
a potato
 
@Poteito so what is the issue?
 
fix it
 
7:54 PM
@KendallFrey what's up?
 
!!youtube fix it fix it fix it
 
@tymeJV well yea he forgot to add the lists back :D
 
7:55 PM
@Poteito you never did anything with newLI, otherwise it seems to work just fine.
 
@SterlingArcher My question is: Why did you think your phone was lost?
 
but that doesn't overwrite anything
so I'm still confused what his actual issue is
 
yeah me too
 
@KendallFrey because I'm retarded?
 
no but why
like was it in your pocket instead of in your hand or
 
7:57 PM
Do I have to pay if I want my github repo to serve "releases" ?
 
@rlemon Well the end result is <li>Arrays</li>but I want to have them all like <li>String</li><li>Integer</li><li>Objects</li><li>Arrays</li>
 
@KendallFrey I've already wondered where my phone was while texting
so... yeah
 
@Poteito -- I see all of those <li> elements logged to the console?
 

« first day (1907 days earlier)      last day (3048 days later) »