« first day (2298 days earlier)      last day (2875 days later) » 

00:05
@10Replies p.s. you don't even need .valigner regarding the previous example jsfiddle.net/dqf94dzu/2
00:29
nice, unreal editor crashes if you try to print a float as %s
@towc I was looking through your codepens, and we have some pretty similar stuff. This look like anything you made? codepen.io/Thisisntme/pen/KNpPEz
wow it works with a so small code :D
@neoDev And two entire libraries
oh ok
00:51
@towc and apparently everyone does the network thingy where once nodes are a certain distance from eachother they become connected... codepen.io/Thisisntme/pen/WxKaKQ
@littlepootis I registered a slack account and I am browsing for open channels... I guess it a good place to meet people :)
Google continues to dump down Chrome by removing https details from the address bar padlock.
yes, it is. There are a few nice channels.
01:56
YAY! figured it out!
All I needed was
  display: inline-block;
  vertical-align: middle;
Took me several hours more then it should have... But I learned things!
Hawaii islands in sunglint. Some #EarthArt to end the day. https://t.co/KOFuitrOPT
cc @rlemon
02:12
where to learn DOM effectively?
Google?
I learn DOM from udemy,but I need to know its use cases.
@jacobian what you mean "learn DOM effectively"?
14
Q: What is DOM? (summary and importance)

VoodooChildWhat is the Document Object Model (DOM)? I am asking this question because I primarily worked in .NET and I only have limited experience, but I often hear more experienced developers talk about/mention it. I read tutorials online but I am unable to make sense of the whole picture. I know that i...

well yes, thanks
02:14
You can learn DOM from me
I've got the expertise
Alternative expertise
He is smart. Like bing.
I can ask question about DOM from you. that is good.
I'll ask later then
you mean like kellyanne conway's alternative fact?
you use HTML to define the inheritance/structure of the DOM; HTML is just data markup, like XML. WHen the browser parses it, it turns the markup into DOM Objects, like Elements and Nodes
jQuery can be useful for DOM manipulation
02:16
HTML is no longer HTML once it's parsed
@neoDev yes
@neoDev It's a lot less useful than you might think
It's not jQuery.
@ndugger why
wat
@neoDev A lot of what it did was tried to normalize the API between different browser implimentations. If your target is mostly modern browsers, jQuery quickly just becomes a redundant, slow layer on top of the DOM API
02:19
but is also true that is widely used and aprreciated
Just like internet explorer!
And laravel
@neoDev Just because it's widely used doesn't make it good or not redundant
sometimes doing things like hide() show() is very easy
@neoDev myElement.style.display = 'none'
02:20
I need to learn laravel in udemy. great php framework ain't it?
You don't need jQuery for that
@jacobian no.
Please, no.
if you put it in this way, even document.querySelector it's never used by anyone
no what?
You don't need a framework.
02:22
function hide (element) {
    element.style.display = 'none';
}
@neoDev That claim is utterly false
I use querySelector like every day
unless I'm writing code that uses a modern framework and then you basically don't need it, cause touching the DOM is a smell.
but should be some very useful jQuery things that are a bit complex to do in plain JS
02:23
nice tutorial. I need to spend time to read it then
nothing comes to mind atm
but there are
@neoDev There's only one thing that becomes a bit more complex without it, and its usecases are very limited anyways.
I have never actually used jQuery lol.
@neoDev nope
XHR is easy in modern browsers
02:24
If you really think that JS is too complicated without jQuery, you probably don't know javascript well at all
Animation is still hard, but jquery sucks at that too
jQUery animations are so fucking buggy, due to the queueing that it does
ok guys, you are right. but jQuery was my friend...
3
:)
Time to move on
turning objects into query strings for GET, it's good at that, but so are lots of small things
02:28
Object.entries(myDataObject).map(([ key, value ]) => ${ key }=${ value }).join('&')
no jQuery needed
understood
Lol, I just googled "Why you should use jQuery"... and I found this article javaworld.com/article/2078613/java-web-development/… The peeps at javaworld don't quite understand javascript...
benefits I received from this chat are unestimable
That article is from 2012
"If Adobe Flash isn't installed on any given browser, certain parts of the page may render incorrectly, if they render at all. This is not only unpleasant for the user; it forces developers to spend extra time coding for the browsers that lack the Flash plug-in, which adds to development time."
From before flash died.
02:33
flash has died?
facebook live use flash
If anyone tells you otherwise, they should probably quit their job and live in a cave
lol
02:34
I use ubuntu and I know the important of having flash when browsing stuff
Flash is good for two things. Flash games and flashy advertisements.
sometimes I need flash to watch streams
and also video editing
no
Good lord
02:35
Youtube is switching to HTML5
You don't need flash to torrent.
YouTube has been on JS video players for a couple of years now
Safari doesn't even have flash enabled by default
Safari is a garbage browser, so it's generally not the best example to give for anything
would be cool find an IT job for me
Safari has gotten better.
02:36
It's pretty much the new IE
Its dev tools are even worse than IE's
problem is that I didn't go to the UNI
no company will employ me
safari can only be use in mac.
Maybe it sucks for development... But safari runs at a decent speed.
@neoDev Nonsense. I dropped out after a semester, and plenty of companies fight over hiring me
I just turned down an offer the other day
you might be very good... I'm so noob
02:38
Then get better
is what I do every day
but I wonder what should I do to be employed
Tons of personal projects
I recommend crying in a corner.
have code on github that you can show off
I made a lot of personal projects, I am organising myself to put some stuff on Github
be working in a team is my dream
what scaries me is also the security
I am sure that when somebody will look at my stuff will find bugs and holes everywhere
I define myself more a front-ender
02:43
That's inevitable. No code is perfect
what pushes me to never give up is passion
the other day I had a lokk to microsoft luis, it looked cool IMO
I tried it, and I realised there was no way to use synonyms as components for the utterances
so I decided to roll my own
and I did it
I was so proud of myself
I created database, admin, client-side... is cool for me :)
I'm proud of you too, my son
now I plan to put it on Github
@littlepootis thank you :)
today I discovered stackshare.io
see all those "Tools" icons it's kinda therapeutic
03:03
to get a job you basically need to create some games using javascript and post the link somewhere so people can notice you
it works for me though
That's terrible advice
and that's why having hosting account is important.
unless you want a job making games
it just to show people that you can code. that's all that matters
Not entirely. You should show that you can be practical. Games are not a practical thing for businesses
03:05
solve problems should be important
practical problems
life problems
If you spend all of your time solving the wrong problems, that's a red flag for hiring managers
Taking notes here... Still in school lol.
and also reading newspaper is important in getting a job
03:07
Uhhh... is it the year 1994?
That's also terrible advice
serious company post ads in newspaper to get serious.
Maybe for local startups...
Absolutely not
yeah I read newspaper. local paper
Good lord
Nobody listen to this guy, please
03:08
Or for your local coffee shop... if thats where you want to work..
@jacobian WAT
sorry for caps
@jacobian lol
This guy is obviously a time traveler from the past.
so none of you read newspaper anymore? everything is on screen?
Everything is on screen!
Absolutely. Newspapers are dead
03:10
I do. But that's because my local newspaper's online version sucks.
But you don't read it for job listings; let's be clear
Of course not. I read it for the noose.
and also about the CV, your CV need to be only 1 page. more than 1 will be boring for HR
I actually agree with that point, mostly.
If you have enough projects that are interesting and warrant more information, then more than one page is acceptable, but NOT MORE THAN 2 PAGES
And do not use colours or flashy designs on your resume. You're a developer. Give me text, bullet points, lists, etc.
makes sense
03:14
I like to use my own resume as an example of this docs.google.com/document/d/…
brb, gotta smoke my last cig
Serif > Monospace
that resume is hard af to read
I haven't had complaints before
I've only heard good things
Except for one dude, but he was clearly clueless. He wanted my resume to be colourful and more like a designer's resume...
Needless to say, I chose not to move forward with that interview
03:29
Use a better font
Nah. the monospace helps me control the size of the content in order to better fit it onto one page
I also like how it looks as monospace
there are no college information in your resume. it's important to put one
There are nicer monospace fonts
@jacobian no
03:58
the laptop that my office gave me did something weird that when I press shift + 2 it shows this " and not @. how to change the button shift+2 back into @ symbol for email address?
04:12
never mind, it's the input method problem in windows.
04:54
Hi. Could any one guess whats the unit or scale of this frequency? -> bl.ocks.org/mbostock/3885304#data.tsv
what do you get if you add them all up?
something close to 1
the graph appears to show "percentage" as the Y axis.
that was when you saw the graph :)
@deostroll yeah. Get it?
05:14
Okay, would anyone know how to intervalize a sequence or sample of numbers (sufficiently large) into say n intervals in d3.js ... is there an api for it?
05:57
Hi
@jithender 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.
06:41
Hello
07:00
YISSSSSSSSSSSSS
I want to create game in html5. anyone has this kind of expertise?
you mean create a game in javascript. HTML5 is just a buzzword that people throw around when referring to the canvas element. All of the game is written in javascript.
yes it's in javascript. using jquery. I am developing it now
I can ask you right?
Why would you use jQuery to make a game? How does that even work? You make my head hurt
well my boss gave me this happy meal game and wanted me to fix some button and stuff
07:07
wat
yeah, I'll fill in later. right now I am traversing the code line by line
nick, don't forget that there are language barrier issues
if you ask me, he needs to check a jquery project to "fix" some functionalities.
not sure if troll tbh
Is there any way to perform certain action of a button without pressing the button in javascript ?
I mean.. what action to performed after pressing a button (say.. ok, submit) is to be performed automatically.
either call a function or you can manually trigger events
07:23
using onchange .. jquery ??
you can do that with js only ...
google for "js manually trigger event"
Geez, a meta topic about trump?
Politics have always been explicitly off-topic.
07:44
It's not about "politics" any more at this point
08:04
i´m running a node script via cronjob on my linux machine. The script is executed, but it doesn´t log my output, whereas my normal node app does log everything I told to do. I´m watching at /var/log/syslog. Where else could I look?
i´m running it as root /usr/bin/node /path/to/my/script.js
You can say one thing for trump though, he keeps his promises vOv
The one time a president actually does what they say -_-
I dunno about that.. he was going to make america "great" again, this seems the opposite
but w/e
TypeScript users, what do you use for debugging?
^
@ivarni He said he'd block immigration, he said he's build a wall
Seems like he's doing one and on his way to do the other.
08:10
That's a pretty basic interface, but I respect that
@MadaraUchiha So he keeps some of his promises, like most politicians
This reminded me of some alternative. Thanks for reminding me guys.
And/or girls
my google fu is failin
i want to "tab" a sentence that is added by js
but   gets displayed as " " instead of a tab
tab as in indent?
yeah.
// init
const foo = ['sentence 1', 'sentence2',  '  tabbed sentence'];
// in loop i = 0 -> n
   const p = document.create....
   p.textContent  = foo[i];
   div.appendChild(p);
// done
08:15
@KarelG Any particular reason you aren't giving your p elements a margin or even text-indent?
that p element has a class name that has a CSS attribute before
padding-left breaks that icon alignment
And text-indent?
never heard of that tho. Gotcha try that
breaks the alignment too
o/
8 messages moved to Trash
!!> ' '.charCodeAt(0)
08:24
@MadaraUchiha 8195
!!> '\u2003'
@MadaraUchiha " "
@KarelG Try that ^
was searching for that unicode :P thanks !
09:02
Why is there a difference between this:

var test = '{"val1": 1, "val2": 2}';

and this:

var test = "{'val1': 1, 'val2': 2}";
?
Because the second one isn't valid JSON, double quotes only.
@Pigman168 Because they're different strings?
@BenFortune Ah ok thanks!
Bit of a noob question: for those of you who use JS on medium/large projects, what is your workflow? I come from an OOP environment and I struggle to give my JS programs structure
@Petar 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.
09:10
@Petar It isn't really a noob question, and I'm afraid I don't have the time to answer it properly at the moment 😬
@MadaraUchiha fair enough, if you get a chance, let me know :)
@Petar Frontend or backend?
device drivers
@OliverSalzburg, both, but more interested in backend for now.
@Petar Node modules pretty much guide you on your structure. If you're using a relatively modern Node, you have classes, so there's that from the OOP world. What you lack in namespaces, you substitute with folder structure and naming convention
09:23
Hi there
need some explanation about a short piece of code
When I was working primarily in C#, I composed applications from classes. In JS I compose applications from functions. So following the same design principles doesn't work
@OliverSalzburg I need to understand more about Node in that case. I will take a look, thanks!
@OliverSalzburg yeah, I need to get used to some design patterns I guess... and overcome my hatred for functional programming
login(user){
    let headers = new Headers();
    headers.append('Content-Type','application/json');
    return this.http
        .post(
            '/API/login',
            JSON.stringify(user),
            { headers }
        )
        .map(res => res.json())
        .map((res) => {
            if(res.success){
                localStorage.setItem('auth_token', res.auth_token);
                this.loggedIn = true;
                return true;
            }else{
                return false;
This seems to fail at line :
if(res.success)
res is :
@Petar If you don't hate what you're doing, you haven't done it long enough
{'user':'username', 'auth_token':'jfqmskjdfqs.djskqfjdfqj.kqsfjmdskjf'}
So, basically, this fails because the object returned has no property "success". But why is the ".map" function called twice? And, why isn't there any ".subscribe" call anywhere?
09:31
angular.element($0).scope()
@OliverSalzburg if you graph hatred vs time, its probable more of an inverse parabola ;)
it breaks when I disable angularJS debug... which makes sense, but is there any quick alternative ?
@Mathematics You mean grabbing the scope associated with a DOM element without debugging information enabled?
Anyone here has experience with proxyquire and karma? I can not make them work together, as requiring proxyquire
```
files: [
{pattern: 'node_modules/proxyquire/index.js', included: true},
]
```
Does not work out due to the requires in the node_module. Do I need to browserify somehow it and then include in karma config?
@MaksimLuzik 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.
09:38
@OliverSalzburg found the fix - github.com/angular/angular.js/issues/9515
Hello i have a design problem in nodejs
I have a function called createOrder which creates a new order. My function code become 300 lines and some functions are getting called from other files. i am thinking of using PUB/SUB pattern for making it readable but it is said that i can only have 10 subscribers.
user3119231
o/
!!> '→'.charCodeAt(0);
@KarelG 8594
09:53
man i'm lazy
!!> '→'.charCodeAt(0).toString(16).toUpperCase();
@KarelG "2192"
Numbers always look so much better in upper case
4
keh. Ya know that the string can return unicode chars a - f :P
!!> '&'.charCodeAt(0).toString(16)
@KarelG "26"
<.< idk which one has chars on it
10:08
@CapricaSix Weird. 26 is the code of → on the numpad. It comes full circle
Very important code to remember ;P
 
2 hours later…
user3119231
11:45
@OliverSalzburg hahaha made my day
@OliverSalzburg Base 16 numbers?
!!> '💩'.charCodeAt(0).toString(16).toUpperCase();
@MadaraUchiha "D83D"
@KendallFrey what is this game even anymore? gfycat.com/UniformBiodegradableGallowaycow
@striker_axel What?
Why would code you write be limited to such a specific number of consumers?
Where was that written?
12:01
@MadaraUchiha not consumer but specific number of lines
@striker_axel I don't understand.
@rlemon Which game is that?
KSP
wat
KSP has robot fights now?
KSP has everything you mod into it
If you build it, they will fight
12:06
I was asleep; my flight hit turbulence. Dreaming brain interpreted it not as “about to die” but “diverted to Glasgow”. Specific fear, there.
I have a function which creates order (let's say it CreateOrder ) for food. whenever this function is called i am calling many methods like updating database
12:24
!!< "23".toLowerCase();
@jAndy That didn't make much sense. Maybe you meant: 0, 1, 3, i, d, y, !, ^, π, ?
"²³"
12:41
My option to add to watch in Chrome Debug has gone... same on a mates computer. Any one else have this?
Yes, I can see that Oliver, but I have to manually type it. I used to highlight a word, and then right click and add to watch @OliverSalzburg
@MyDaftQuestions Highlight a word? Like a word in this chat?
Yes. I could double click a word to highlight it, right click on it and choose "add to watch"
Now that option has gone
Well, you should really be highlighting text in code, not general text on a website
Optimally, code in the DevTools
12:45
Oh I'm sorry, I mean in dev tools
That's what I get
Ah,... it's been renamed
And I just coudln't see it
My goodness, 2 of us were looking for this
arrrrggghhhhh
Well, thank you for your help (again)
You're welcome

« first day (2298 days earlier)      last day (2875 days later) »