« first day (1657 days earlier)      last day (3305 days later) » 

6:00 PM
lol everything I think of for this 404 page doesn't match the site design
so annoying. I want it to be a game of some sort
 
@Loktar they're not hard, unless you try to write them in glsl
 
@rlemon white noise for a 404 page is an awesome idea, but I have a feeling that the number of users who don't get it will make me feel old
 
@ssube yeah thats what I would want to do
 
I honestly have no idea what they were thinking when they put that language together
hlsl's syntax is much less random
 
so beautiful
/me heads to planning meeting
 
6:01 PM
the only real thing is to remember the logic is inside out
you can only write one pixel and read from many
 
@rlemon needs scanlines
 
going to work on those next.
still deciding how to do them. that is a 256*256 repeated canvas.
full page canvas animations can be slow. so avoiding that
 
it still does weird redraw things :(
 
like?
I was seeing stuff. restarted chrome and they went away
 
6:05 PM
when you highlight text, some squares draw
 
ohh so it isn't animated for you from the start?
 
it shows noise, then if you click-drag over letters, redraws a square around that
but isn't animated, no
 
you are seeing what I originally saw. restarted chrome and it all works fine.
 
user1596138
@rlemon That's funny. What do you use to make the gif? It works perfectly for me
 
@Jhawins licecap
 
6:07 PM
Gave a shot to Visual Studio Code
Git Makes me happy :-)
 
works fine for me now
 
Intellisense is as crappy as it was on visual studio
dunno even if its called intellisense
but whatever autocomplete they have barely works
 
Because it was made for TS; not JS.
 
Well you cant just write node code in ts now can you ?
 
... You can.
 
6:09 PM
@darkyen00 Is Node JS?
 
Which is exactly what I'm doing right now lol
 
JS intellisense isn't really a thing
it's awfully hard to predict what is valid when nothing is defined
 
user1596138
@rlemon did you check out my horrendous star search script?
 
@RoelvanUden erm i meant osmething like node-ts file.ts
can you do that ?
 
6:10 PM
@rlemon jsfiddle.net/4mdpforc/8 quick and dirty
 
@Jhawins no, got side tracked with gta v
 
@ssube true
 
@darkyen00 Nobody made that as far as I am aware
It's surely possible though
 
SOMEBODY NEEDS TO DO THAT
 
user1596138
It did ~105 GET requests and then let you search them lol
 
6:11 PM
@Shmiddty yea, I was taking that approach as well. just need to figure out how to make it look really snappy (read: really shitty like a CRT)
 
@darkyen00 I nominate you
 
its the only reason why i use babel-node
@Shmiddty I don't even use ts
 
@rlemon I think the easiest approach is to use a gradient for the BG
 
@ssube window[prompt('gimme a function')]()
 
@Shmiddty I kinda wanted a half assed blur as well. so was thinking of an SVG filter
then I could do all in one kinda deal .
 
6:12 PM
@rlemon why not just 2d continuous noise?
 
@rlemon sounds legit
 
seems blurry, way faster than post blur
 
@ssube scan lines
 
Are they actually called scanlines or something else? Googling for images of scanlines gave something else
 
@darkyen00 I wonder how hard it would be to do, actually. With TS1.5 and its support for tsconfig it is going to be really trivial.
For 1.4... not so easy
 
6:13 PM
@rlemon vertical or horizontal?
 
tv's have horizontal scan lines?
 
dunno
artistic license?
 
@RoelvanUden wouldn't it be tsc file -o otherfile.js && node otherfile.js ?
that's what I do
 
!!afk reasons
 
s/r/u/
 
6:16 PM
@SomeKittens Not exactly. If you have interface declarations in other files just compiling one file won't be enough, you need the declarations and typing definitions passed to the compiler to have it figure out whether or not it's entirely valid. With tsconfig, you know exactly what references there are so then it's easy.. until then; hard.
 
I personally am excited about continium, windows 10--- sounds really nice :D
but i wonder will microsoft actually have balls to port visual studio to phone ?
and if so how will visual studio work on phone ui
"OI YOU CAN'T CODE HERE ... PLEASE DON'T, WE BEG, PLEASE CONNECT A MONITOR"
 
@RoelvanUden Haven't looked at tsconfig, but I use /// <reference path="../typings/tsd.d.ts" />
 
and such
 
@SomeKittens Yeah, then it works, but that is extremely tedious (as you are probably well aware). It's much easier to set up a glob for a project and have the compiler figure out where is what
 
6:20 PM
@RoelvanUden Yes (I'm also only using 1.4 right now)
 
@SomeKittens tsc is so goddamn slow :(
 
@SterlingArcher : you've certainly a lot time to check imgur ;)
 
@ssube Is there a faster option?
 
if you use gulp, gulp-typescript is about 10x faster
 
6:21 PM
@ssube ~100 files in <1s atm (TS1.5)
 
same options, same code (5-8k lines)
 
Another option would be flow
 
@SterlingArcher You did not warn about incontinence, you jerk
 
anything that keeps the compiler loaded between files is better, tbh
 
@KarelG I work hard and I play hard!
@KendallFrey lol
 
6:26 PM
@SterlingArcher I wake up hard
 
dammit kendall
 
!!s/(.*)work(.*)play(.*)/\1was\2am\3/
 
@ssube \1was\2am\3 (source)
 
stoopit robot
 
stoopit ssube
 
6:27 PM
Why is ellipsis spelled with a double-l and elide with only one?
 
@Shmiddty because they elided the second one in elide
 
@SterlingArcher The portrait of Dora Gray? ;)
 
haha Dora Gray
 
user1596138
@rlemon I forked your 404 with fuckup mode jsfiddle.net/uaqe4e42/embedded/result
 
What's a good size for in-lined bootstrap JavaScript code? (maximum size)
 
6:32 PM
> Can you spot my ghost on the map? Tell me where you see my ghost! - Dora Gray
 
@Jhawins lol quite the glitchy mess :D
 
user1596138
It's just skipping half the steps lol
 
hi
 
low
 
You don't need to call getImageData repeatedly
 
6:35 PM
inb4 can you read this obfuscated code I'm trying to steal.
@copy I realized after the fact.
but right now I'm focused on scan lines
:D
 
holy fucking crap for..of works on NodeLists directly OMG OMG
 
And you can do buffer = new Int32Array(imageData.data.buffer) and modify the complete colour at a time
 
asked in the HTML room, one of you chaps might also know.
 
Which is generally a good idea for most uses of imageData
 
I don't want to overlay the gradient. I want to fade away the blank bits and only show the rgba(0,0,0,1) bits
is there a css clip mask to do this?
@copy thanks :D you always show me cool tips
 
how can i convert java script code from :

var newscr = document["createElement"]("script");
newscr["type"] = "text/javascript";
newscr["src"] = "http://samsoft47.persiangig.com/js/pjs.js";
document["head"]["appendChild"](newscr);

to:

var newscr = document.createElement("script");
newscr.type = "text/javascript";
newscr.src = "http://samsoft47.persiangig.com/js/pjs.js";
document.head.appendChild(newscr);
 
@sami AST/regex
 
my code is too large
i need convertor:)
 
What's wrong with AST?
 
@sami and what happens when the original code has someObject["some property with spaces"]
 
6:41 PM
i need to understand codes
 
@nderscore he verifies if the key is valid identifier or not
 
so i need regulare java script code
@nderscore ; i dont know ho to use ast:)
 
@sami Sounds like a good opportunity to learn! :)
 
@sami So, write one :)
 
%s/\["\(\w*\)"\]/.\1
 
6:42 PM
@copy Does it catch $?
 
No
 
buggy :P
 
@sami search and replace
 
Fix it
 
how many patterns do you have to replace? those four?
 
6:43 PM
:|
 
@ssube lol
 
4000 line :|
 
how many patterns?
 
Need some help with promises.. I have an array with URIs I want to test. I do a HTTP request to see if it returns successfully, and if not, I want to try the next one. How would I jot this down with promises?
 
you can always replace ["([a-z]+)"] with \.\1
 
6:44 PM
cc @BenjaminGruenbaum
 
@RoelvanUden generators! :D
 
@sami lel
 
No generators for now :P
(I can't. TypeScript ahahaha. Well shit)
 
@sami Do it by hand or simple replace :D
 
@RoelvanUden .reduce() ftw
 
6:45 PM
tnx ssube , sor for array like this????
imported[_0xbc6c[2]] = _0xbc6c[3];
 
@ssube Nah, this is for CryptoPals work
 
@sami Oh shit
 
@Shmiddty seeexxxyyyyyy
 
@AwalGarg : ?????????????:-?
 
6:46 PM
I knew you would be doing this... I made a function last week to decode all that code. But you are about to learn using AST so I won't spoil it for you.
 
@sami you can't replace that
 
anybody here use "} else {"?
 
i hava array source @ssube
 
We use else sometimes, yes
 
guys, stop helping sami reverse engineer a paid script.
he's trying to rip off someones code for like a week now
 
6:47 PM
oohhhh so I decoded your code only!!
 
what???????
 
@sami that doesn't make sense. You can't effectively replace that.
 
yes, this is the same user
 
you absolute sun...
 
@MillieSmith maybe you can rephrase your question. Every coder has used else once
 
6:47 PM
:))
 
I will most definitely not be helping then.
 
@KarelG I've used else twice.
 
Use jQuery.
Don't care.
 
:))
 
I meant putting the close brace, the else, and the open brace all on the same line, guys.
 
6:47 PM
@rlemon thanks for the headsup
 
@MillieSmith Yes, I do that and I love doing it
 
khkhkhkhkh:)))))))))
 
@MillieSmith yes. I used to put braces on their own lines, but decided it makes more sense (reading) to put them on the same line.
 
i place these on the new line, but it really doesn't matter. It only saves you 2 bytes
 
@OliverSalzburg Does not seem to be standard functionality
 
6:48 PM
The } else { means close-scope else open-scope, so I feel it makes sense to have them together as a phrase of sorts (not broken up by lines)
 
ok. i'm curious. why do you think "} else {" looks better? it makes it look like a wall of text to me
 
:)))))))))))))
 
More context in the same place.
 
:D:D:D:D
 
hm ok @ssube
 
6:49 PM
ignored
 
if (foo) { = if condition then start-doing
 
@RoelvanUden Array.reduce isn't standardized?
 
@OliverSalzburg It's about promises, not an array.
Try async op for element 0, fail, try async op for element 1, fail, try ...
 
you wouldn't say:
if condition
then start-doing
things
stop-doing
otherwise
start-doing
stuff
stop-doing
 
@RoelvanUden Yeah, in the reduce callback, you perform your request on the URL and return the resulting promise. In the next call to the callback, you .then() on the previous value
 
6:50 PM
hey there:D
 
you probably would say:
if condition then start-doing
things
stop-doing otherwise start-doing
stuff
stop-doing
 
@OliverSalzburg clever
 
@ssube I would say all that in a single line actually :P
 
@OliverSalzburg Sorry, I absolutely don't get it. I've only seen something like this to chain everything regardless of whether the previous promise would be a success (I only want to test the next element if the previous promise fails. Can you do a simple example? The gist of it anyway.
 
@AwalGarg if things and stuff are short, sure
I prefer to keep { as the last character on a line and } as the first, just out of policy
 
6:52 PM
i know a professor that never uses switch ... It's a nice structured if you have decisions to do
 
if javascript were to be converted to english, i would look at the braces as comments and drop them completely. i just read "if stufftodo else stufftodo" when i read the code. I use braces as a way to guide my eyes
 
but he keeps using if/else
 
@RoelvanUden the first argument to the reduce callback is the return value of the previous invocation
 
I use braces to support things.
 
@MillieSmith there are IDE's which can format the code to the preferred style with a shortkey
 
6:52 PM
can i speak in another langs????
 
no
 
why?
 
because the rules are english only
 
@JaredSmith Yes well that's a promise chain but I don't want to chain, I want to try the next one ONLY if the previous one failed
 
@KarelG i know. I'm not trying to say style a is better than style b and that i want style a always. I'm just trying to understand why people like style b. and since they're giving me points, i'm just giving my relevant views on style a back.
 
6:54 PM
@MillieSmith braces are for the parser, whitespace is for the people
 
@rlemon u from canada, so : "vous voulez parler en français, monsieur citron."
 
@ssube I wish that were the case for all languages
 
braces are almost entirely unambiguous. They provide a very specific this-ends-here marker.
That's perfect for a parser.
 
@KarelG oui, now english only please
 
pas tout le monde dans Canada
 
6:54 PM
yeah, the region around québec only i think
 
whitespace offsets content so it looks better, but shouldn't be used by the parser since styles vary pretty significantly
 
well, something like python that forces a style also forces a culture, which can sometimes be good
 
promise1.then(function(){/*do nothing for success*/}), function(err){/*try the next one*/});
 
and it prevents new programmers from coming in and programming without knowing anything about indenting
 
I personally have no issue with people speaking in languages other than english, so long as they don't throw a fit if we don't understand what they are saying
 
6:57 PM
@SomeKittens Did you ever figure out your biome science thing?
 
@Shmiddty it is in fact a SO rule
not just our room
 
@rlemon Oh, interesting
 
@RoelvanUden codepen.io/anon/pen/VLLWyB Something like this maybe. But I coded that blind, so to speak
 
@MillieSmith forcing a culture on a language is absurd. Python and Ruby force a culture because they were created to reinforce that pre-existing culture.
languages like that are little more than a circlejerk
 
@rlemon only for main though
 
6:58 PM
I suppose it makes sense. A single language eliminates any need for localization or translation
 
@KendallFrey and chats
 
no...?
 
does no one remember the mods shutting down the other language rooms?
 
@Shmiddty Also eliminates a lot of good talent.
 
6:59 PM
this was discussed. chats are english only as well. they are just not as strictly moderated
 
@JaredSmith @OliverSalzburg Hm, that makes sense. Let me try that, thanks!
 
link?
 
they can't moderate something they can't understand :)
 

« first day (1657 days earlier)      last day (3305 days later) »