« first day (2290 days earlier)      last day (2650 days later) » 

12:03 AM
@WATERYMEL0N I would think.. but evidently not.. somehow.
paint one big rectangle, then the alternating stripes.
 
I was playing around with canvas for the first time and tried to draw a video onto a canvas which I did, but now I can't place the video element and the canvas side by side in the page. I've tried chaging the css and the elements position but nothing.
Can you please take a look at this https://jsfiddle.net/dL0ngL2f/ and see if you spot anything that can be causing thi?

PS: when I manage to change the position the video isn't drawn to the canvas
 
should be about half the time.
 
@Mr.Toxy why do you have a < script > in your javascript code?
 
!!> var a = false, script = true, b = false; a < script > b === script
 
@towc true
 
12:09 AM
:P
 
@littlepootis I copied wrong, ignore that tag
@littlepootis do you have any clue on how to position those elements side by side?
 
Your reduced test case doesn't include any CSS.
 
user6438653
@Luggage Weird.
 
@littlepootis It doesn't yeah. but I've tried to add some css rules and didn't work either
 
user6438653
What is the fastest? jsperf.com/math-round-vs-hack/3
 
12:13 AM
I am the fastest
 
nvm
 
user6438653
what
 
so could android apps technically run on ubuntu?
 
with an emulator
 
12:13 AM
 
f*** emulators
 
user6438653
in the vagina, hehe! Why the sudden ***
 
@William really?
 
@littlepootis really what?
 
I'm going to see if i can get node running on android
 
12:15 AM
@Sheepy I would never be able to come up with that :o
 
on my laptop
 
@William we have king emulators?
 
user6438653
I have a cool emulator, because I'm lame..
 
@Mr.Toxy You can also use table cell display, or absolute both elements.
 
wtf sheepy??
 
12:16 AM
Sorry, wrong ping.
 
@WATERYMEL0N it was a joke. f*** stands for Fornication Under Consent of the King
so it would be "Fornication Under Consent of the King emulators"
 
you really like to ping me sheepy happened the other day also
 
@Sheepy That was my second thougth to use a table. hmmm I will try both, thank you very much kind sir
 
@Mr.Toxy You may not need a real table. display:table-cell with vertical-align in the container should do.
 
@William yes
 
12:19 AM
@Sheepy that is a cool solution as well, thank you :)
 
@littlepootis is it fast enough to develop
you aren't sshed into something right
 
No, native.
 
@William Perhaps this is not the first time I wanted to say something to you in respond but then decided against it :)
 
@William of course not
 
12:21 AM
@William Most smartphone are fast enough to run webpages. Node is not that heavy.
 
I have this bluetooth keyboard that connects to my android
and you can get vim on the playstore ;)
 
or you can get termux
 
user6438653
@TrojanByAccident haha
 
I tried bluetooth keyboard w/ phone too. I eventually decided that carrying a (windows) pad is not much heavier than a keyboard and is much more productive.
As long as I buy a pad that fits into most of my shoulder bags.
 
user6438653
@littlepootis How did you do that? Hey we have the same android.
 
12:23 AM
@WATERYMEL0N termux
 
user6438653
What one? lol so many.
 
@Sheepy hmmm that works fin on fiddle but it doesn't work locally on my computer, it's not drawing the video. Do I need to preload the video or something?
 
user6438653
@littlepootis It can't install node.
 
@Mr.Toxy Beat me. I believe that if I try it it'd work...
 
@WATERYMEL0N I just tried and it worked?
 
12:27 AM
that's really weird, it doesn't for me. Hmmm let me see
 
Me too. Tried and working. Usually there is something wrong with the code that is not included in jsfiddle.
 
user6438653
@littlepootis apt get nodejs?
 
@Sheepy found it, it was an exception. forgot to add something
 
@Mr.Toxy ?
 
user6438653
12:30 AM
 
Ok.
 
@WATERYMEL0N apt install nodejs
 
user6438653
That's there.
 
@WATERYMEL0N apt update
and then apt install nodejs
 
user6438653
right-y
 
user6438653
12:34 AM
Keel thanks @littlepootis
 
install vim too
 
user6438653
vim?
 
user6438653
okay installed.
 
user6438653
I can say by to Simple Notepad.
 
user6438653
12:49 AM
Ummm where does vim save stuff?
 
Wherever you tell it to?
 
I've ran out of woodworking videos to watch
anyone got any new channels for me?
 
how do you feel about chicken framign channels
farming*
 
1:10 AM
I've seen a bit, bee farming is more interesting to me
or generally farming. aquaponics are fascinating
 
/r/beekeeping is my favorite subreddit
 
(cody's lab)
geologist student (masters?) who does farming and bee keeping and other weird experiments
 
My sister was a geology major
 
I like his aquaponics stuff and his mining stuff (old mine on his parents ranch)
but generally, he has entertaining videos and is a big nerd
@KendallFrey holy shit cody has almost a million subs
when I started watching him it was like 200k
 
Do you watch ja towsend & son
 
1:15 AM
yup
 
Jas. Townsend & Son
He's my dude
 
old timey cooking is fun to watch as well
my youtube subs are a mix of cooking/blacksmithing/science/woodworking/crafts/survival/games/puzzle making
ohh and skateboarding videos
I don't skate, but they aare fun to watch imo
 
@rlemon Tom Scott
 
hrm, I thought I was already subbed to him
he shows up in my recommendations enough
 
user6438653
What is ur real name?
 
1:28 AM
that's his real name
 
I can create a folder with javascript but it uses ActivexControls that only work for IE, I've searched and all the examples come up with the Activex is it possible to create a folder in chrome or it justs works for IE?
 
user6438653
Wat what?
 
His real name is Bob.
 
user6438653
Cannot divide by zero solved (0/0) | 0
 
^ 0/0 its a indetermination... LMAO
 
1:30 AM
@WATERYMEL0N Why can't you divide by zero?
!!> 1/0
 
@littlepootis "Infinity"
 
!!> 1/-0
 
@littlepootis "-Infinity"
 
user6438653
!!> (1/0) | 0
 
user6438653
Only works on int tho.
 
user6438653
1:32 AM
Why does !!Infinity return true?
 
because !Infinity is false?
 
user6438653
hahaha
 
because the specs said it was
 
@Mr.Toxy IE only. Not advisable.
 
@Sheepy yeah I know :\ I found something to do with NodeJS I will give it a try
 
 
2 hours later…
user6438653
3:31 AM
EMCAScript.
 
3:55 AM
The Art of Computer Programming is going to get a new section
2
 
That's awesome
 
user6438653
@RahulDesai True, random.
 
4:10 AM
yep
 
 
1 hour later…
user6438653
5:11 AM
JavaSceit
 
@rlemon I love this channel too youtube.com/channel/UCMV8B1Q5lEEb5yR8Hqkbdhg
I don't understand why
Go minty maniacs
 
 
1 hour later…
user6438653
6:23 AM
Why does thia crash? jsbin.com/paxuyixeho/edit?html
 
canvas.width is 0
 
user6438653
Really?
 
user6438653
When you run it, from output. It crashes, canvas width isn't 0.
 
rsu gets too large actually
Idk what it's supposed to represent
 
user6438653
I have a check tho.
 
user6438653
6:36 AM
if (this.radius < 10)
 
is there a this.radius?
looks like it's called this.r
 
user6438653
oh, no, true, thx @Meredith.
 
user6438653
by cya
 
user6438653
7:02 AM
Guys.. I am leaving stackoverflow, my account will be deleted, if you want to contact me, email me @ wateryymel0n@gmail.com
 
user6438653
bye, cya.
 
7:15 AM
The code on this page doesn't do what it says it should do: w3schools.com/html/tryit.asp?filename=tryhtml5_geolocation
w3schools, you've failed me.
 
7:28 AM
@JonahSloan We don't really like w3schools in this room. We usually recommend MDN if you need reference, Stackoverflow if you need code.
 
7:45 AM
Ok, well I copied the code from developer.mozilla.org/en-US/docs/Web/API/Geolocation/… under the header "Geolocation Live Example", and it doesn't work anymore.
 
7:59 AM
@JonahSloan I think it's a device specific problem.
 
Hello Everyone........I have implemented my own version of CKEditor using javascript through modifying the default CKEditor with the help of CKEDITOR.replace(editor1,....).
But problem is the buttons I have used like radio,checkbox, text field, text area are not editable .... as shown in the picture
Could anyone worked in CKEditor 4 previously help me in this regard ?
 
@JonahSloan By "not work", do you mean you get some error message with the MDN code?
@W.Jack A quick google will show that this may be a known issue.
 
user6438653
8:20 AM
I failed at deleteing my account...
 
user6438653
I got dis liitle bit of node.js express code github.com/WATERYMEL0N/sticky-balls/blob/master/index.js
 
user6438653
But I speculate that app.listen isn't working.
 
user6438653
I'm getting a Request Timeout on heroku.
 
user6438653
8:26 AM
@littlepootis Hahahahahaha
 
user6438653
8:44 AM
nv
 
9:02 AM
@Sheepy ... just worked with nid_forms... but it didn't work...
it's really wondering ..... why a simple code for radiobutton couldn't checking/unchecking itself....
When i put the code in a simple webpage... it works fine... but whenever i made a connection of radiobutton with the textarea in CKEditor... it's not working
 
@rlemon primitive technology is good youtube.com/channel/UCAL3JXZSzSm8AlZyD3nQdBA, dude does various builds outdoors, very relaxing
 
9:30 AM
hi There !!
 
@Abdel-Raouf 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.
 
Hello Everyone........I have implemented my own version of CKEditor using javascript through modifying the default CKEditor with the help of CKEDITOR.replace(editor1,....).
user image
But problem is the buttons I have used like radio,checkbox, text field, text area are not editable .... as shown in the picture
Could anyone worked in CKEditor 4 previously help me in this regard ?
 
10:34 AM
anyone know good places to buy different kinds of paper online?
 
11:03 AM
well vlc is the best media player. able to sync subtitle.
 
11:13 AM
Hi, native English speakers.
Are you there?
 
Colleagues, why does the flow pass this code without an error:

/* @flow */
class Foo {}
class Bar {}
declare var f: ((x: Foo) => void) & ((x: Bar) => void);
f(new Foo());
the type intersection requires the composite type to match both operand types
and the new Foo definitely does not fit the x: Bar type
 
@towc printing companies usually keep stock from all the paper manufacturers, you should ask them
 
good point
 
11:28 AM
Is there a decent npm module around for modifying (not building, not parsing) XML files? I just need to an in-place replacement of one value. Right now I'm using execSync with cat, sed and piping it to the file and it's ugly.
All I seem to find are projects that only parse or only build objects from scratch
 
You can't modify it without parsing.
 
well doh, but I can't use a project that only supports parsing
 
What's wrong with the current approach?
 
I want to parse it, modify it and then write it back but I don't want to screw up the formatting and create huge diffs
there's nothing wrong with it, it just feels like a crappy way of doing it
 
regular expressions for the help! :-D
 
11:31 AM
I'm basically doing cat pom.xml | sed -i 's/<${dep}.version>.*<\\/${dep}.version>/<${dep}.version>${version}<\\/${dep}.vers‌​ion>/' pom.xml and I would have liked not having to look at that carwreck in my code
 
^ that's legit
 
I guess I'll hide it away in some utils-file and try to forget it exists untill I find or write a module that doesn't rely on the OS
because that is going to fail pretty hard if someone tries to run it in windows
 
11:51 AM
is there a way to combine componentWillReceiveProps with componentDidUpdate in React? I want to do something after the update has rendered but only when there are new props
 
@joshhunt facebook.github.io/react/docs/… --- it has prevProps
 
right but prevProps will always exist right?
 
it would
but you asked "when there are new props"
you have this.props and prevProps
so you can compare as per whatever your "new props" logic means
 
It sounds like he wants to do something after the following render, though, and not after just receiving props
 
and componentDidUpdate is invoked after rendering
 
11:57 AM
oh wait yeah I was reading that too fast
 
not sure though whether there is a potential chance of multiple updates being squashed into one
 
Ideally I would like to avoid comparing this.props and prevProps and would prefer just to check if any props have been updated. Let me just check something with componentDidUpdate
 
so you want to compare something without comparing it?
 
well componentWillReceiveProps tells me if new props have come in. But I need to wait for the component to update so I can access a ref
 
it does not tell whether "new props" are any different from the "old props"
it just passes you the very current object
 
12:02 PM
yup, that's what I want
 
I'm confused. Before you said "if any props have been updated"
the componentWillReceiveProps might be invoked even if props have not been changed
 
sorry bad wording I guess, I mean the same as componentWillReceiveProps
 
do you have any internal component state?
 
yes
 
now I see: you want to distinguish the render caused by setState from the render caused by a parent component re-rendering?
 
12:06 PM
yes exactly
sorry if my phrasing wasn't very helpful
 
I cannot think of anything not as ugly as just maintaining a flag like this.caused_by_parent_rendering that you set in componentWillReceiveProps and reset back in componentDidUpdate
 
I had a similar problem when I tried to count how many times a component rendered and keep that in state, it escalated out of control pretty fast
I ended up finding 10 different ways to crash the browser tab
 
ah ok, I'll guess I'll go with that option and just comment to make it clear what is happening. Thanks heaps for your help and working through to understand what I was asking :D
@ivarni I guess if you store it in state it will cause a re-render? So infinite renders?
 
Ya, and that brought me to trying to figure out if I was rendering because of a state change or a new prop
It was just for a quick PoC of integrating react components in a backbone app so I just stored it in a global rather than state in the end
using this is probably the cleanest solution by a longshot
 
fair enough. Anyways I had better go to bed. Btw you can usually find me in the html / css / web design room if you ever need help with that sort of stuff
 
 
1 hour later…
1:26 PM
Hello guys can anyone help with this please its urgent. stackoverflow.com/questions/41782525/…
 
@dbkonXepts 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.
 
@CapricaSix alright noted
 
1:52 PM
@FilipDupanović subbed long ago
@Meredith nice, thanks
 
2:07 PM
@Zirak you're overbooked :)
If you want any more feedback on the slides let me know, also feel free to use the room
 
Hey guys, mind taking a quick look?
http://webmasters.stackexchange.com/questions/103087/spam-subdomain-in-russian-in-my-website (Spam subdomain in russian in my website)
 
howdy anyone around
 
2:31 PM
you got pwned
 
@LucasBustamante How do your DNS records look like?
 
3:05 PM
@KendallFrey ahh the elusive space snake. spaceflight.nasa.gov/gallery/images/shuttle/sts-127/hires/… so majestic in her natural environment
 
3:50 PM
does anyone have chalkboard painted rooms?
are they really bad for dust and stuff?
or difficult to maintain?
 
whiteboard the walls instead
 
or alternatives if I wanted something black to cleanly draw on and remove quite easily?
didn't even know whiteboard paint was a thing 0.o
whiteboards are a completely different technology than blackboards though, right?
 
probably isn't. just buy a bunch of whiteboards and glue them to the walls
 
it is (I googled)
 
@towc Probably are.
 
3:53 PM
I actually remember a huge wall with a nice texture and touch to it at FB headquarters in London with things written on it but easily clearable, I think that was whiteboard paint
now, question is whether there's something like whiteboards but black
or I can just cover the walls in paper and use pencils
omg black whiteboard paint is a thing too 0.o
as in, there's transparent whiteboard paint, so you can have anything behind it
although the price is kinda over my budget, for the "easily removable and recreateable setup" :/
> Description: Dry Erase Whiteboard
Product: Paint
Area: 21ft2 - 365ft2 (2m2 - 34m2)
Price From: From £99 - £799
Price per ft2: From £2.19
Finish: Glossy
Colour: Transparent
Application: 1 Coat
Installation: DIY / Professional
Time: 1 Hour Application
VOC: Low VOC
Odour: Low Odour
Primer: Required For Porous Surfaces
Guarantee: 10 Years
also
!!> function a(b){ return b + 'whaaaat'}; athis is a thing?
 
@towc "this is a thing? whaaaat"
 
just use tape, paper, pencil, and an eraser
 
it's a`this is a thing? `
you can call function string parameters like that...
that's just WOWOWWW for me
never seen it used
is it a ES7 thing? Time to do some googling
oh, it's called tagging
 
4:18 PM
@towc es6, and I've been trying to find uses for it
SQL queries are one.
 
major use I saw was codegolfing
it saves 2 characters when defining a canvas context, for starters :P
 
Bah.
 
nuh-huh, it's important
otherwise, I really do think it makes everything less readable
it gives it this kind of unrigid python feel
where you can call functions without parenthesis. I kinda love it, but I really hate it
 
the syntax is odd, but it has value as a feature.
 
isn't it just sugar?
not really a feature
 
4:21 PM
the tagged templte strings. You can do thing you can't do with a normal template string
 
oh
is this where \n doesn't get parsed as a line feed?
 
No. but it does that, too.
 
I must have missed it, then
 
backticks are template strings. FOO`` is a tagged template string
it calls a function with the string and it's "parts"
see an adlib example I made: jsfiddle.net/luggage66/zq7cgoc7
 
oh, I see
 
4:23 PM
See that I'm passing in a array to the template string, but since' it's a tagged tempalte, I can pre-process all the items that you put in ${}
And that pro-processing is where the potential power is.
 
so it just saves you a bit of hassle, rather than you writing a proper model for passing things around
 
a "proper model"?
 
ya know, rather than passing the string, you may want to pass the things you'd pass in the string instead
 
No. That's just regular tempalte strings
this does more. It allows you to process them in the tag function.
ADLIB `${['He', 'She']} ${VERB} the ${NOUN}.` does things that just `${['He', 'She']} ${VERB} the ${NOUN}.`
!!> ${['He', 'She']}
 
@Luggage "He,She"
 
4:26 PM
Does anyone have any ideas of what to build this into? githubgame.github.io/1
 
I might still not have gotten it. What I got so far is that meh `${a}{b}{c}` is closely equivalent to meh( `${a}{b}{c}`, [ a, b, c ] ), right?
 
meh(['', ''] , a, b, c)
That allows you to work on the structure of the string. Sure, it's "sugar" but you want sugar when your purpose is to let you write a string and get structure out.
 
hmmm ok
 
The best example, is parameterizing SQL.
 
I see your point now
 
4:30 PM
let query = `SELECT * FROM SomeTable WHERE id = ${id};`; // this is vulnrable to "sql -injection"
 
prepared statements
 
let query = SQL`SELECT * FROM SomeTable WHERE id = ${id};`; // this is __not__ vulnerable to "sql -injection" with a proper SQL() function defined.
 
Has anyone here ever thought of creating a small scripting language based on C?
 
@Asperger go on...
 
Here is an SQL() for the above: github.com/brianc/node-postgres/wiki/…
 
4:32 PM
I'm intrigued by your question.
 
@Asperger um.. javascript.
1 min ago, by Asperger
Has anyone here ever thought of creating a small scripting language based on C?
^ No sentence has probably been more uttered.
 
JavaScript isn't small.
 
No question really, I just tried something. Wrote an extremely simple program that basically reads a piece of string, basically a custom function syntax and converts it to c code and executes it
the function looked like this:
func() { log(1) }
 
ah, a transpiler?
 
@Luggage C++
 
4:35 PM
Java
 
@Luggage if thats what you call it, then ya
no regex involved
 
if it 'compiles' to another high level language, then it's a transpiler
 
is javascript a transpiler?
 
4:36 PM
I mean the engine
 
no, but typescript is
 
What engine?
 
well tsc is.
 
Depends on the engine.
 
so javascript doesnt have a transpiler that converts the script to c code?
 
4:37 PM
There are transpilers, compilers, mutilators, interpreters, whatnotinators.
 
oh ok
though transpilers and interpreters were the same thing
 
correct. javascript is either interpreted, or compiled into a bytecode
no "c" involved.
well, the engine may be written in c, but never is the JS translated into equivalent c code as a step
 
JavaScript can't really be compiled.
 
Im going to google this
 
You'd still have a pretty large overhead.
 
4:40 PM
it says: translate source code into some efficient intermediate representation and immediately execute th
intermediate representation , thought that was the c code
bit confused how it works to be honest. Understood the concept of transpilers and compilers though
 
unlikely.
 
@Asperger Google "JIT compilation"
 
c is for humans. any intermediate format is likely a bytecode or something other structure for computers.
 
So js -> bytecode -> machinecode
 
There need not be any machine code involved.
 
4:42 PM
js -> bytecode -> engine/runtime
 
That depends on the implementation, really.
 
So just the syntax is based on C, its not like they have to convert it to c first but to bytecode.
understood
explains it really good.
so typescript etc are preprocessors right?
 
No, typescript transpiles to JS.
 
Ok get it
@littlepootis so its wrong to assume that typescript is a programming language?
 
No, typescript is a programming language.
TSC is a program that transpiles Typescript to JavaScript.
TypeScript markets itself as a superset to JS. So it behaves that way.
Typescript NEED NOT compile to JS. But it does.
 
4:49 PM
but does it work on its own? Does it have a vm or something
 
Programming languages are abstract entities. They can't work on their own.
 
ya right
so if I create a transpiler that converts a custom language to lets say c then I can call that language a programming language.
 
of course
 
which well transpiles to another language to be executed
@littlepootis still got a lot to learn. Im currently in a vocational programming school so it really helps to know these things
 
that depends on what the user intends to do with the C code generated
He could compile it, or interpret it.
 
4:52 PM
a language that transpiles to another is a good way to take advantage of pre-existing tools to get a new language started.
If you keep the same language semantics and just have a new syntax only, them it's almost just a macro-langauge. Or you can go further, and have your own language features that translate into many lines of c.
 
@Luggage I will never create a language because the amount of planning is simply insane and hard but its definately interesting.
 
There's no such thing as a "transpiler", "transpile" was a word invented by 6to5 (now Babel) because "compiling" was a bad word in JavaScript.
 
Well, it was invented, so now it's a word. :)
 
If you translate from one language to another, even if you translate from one level of a language to another, you're compiling.
 
@MadaraUchiha nice for clearings things up. Didnt know that
 
4:59 PM
@Luggage It's a word that means something to salespeople, not to programmers.
 
you take that back
 
"No, no, don't worry, it's not a compiler, it's a transpiler, it's shiny!"
 
I will not be called a salesperson. :)
 
lol (ya just lol)
 

« first day (2290 days earlier)      last day (2650 days later) »