And even angular recommends.

 
Idema: You grew up speaking only JavaScript? How did you learn English?

Couillard: My first programming language was BASIC on Atari 8-bit computers back in the 1980s.

Remer: Interpreter was slow and inefficient as hell.

Hankey: Suddenly I feel young again

Aguon: My dad started programming in the 1960s, in raw binary input on old mainframes with exotic word-sizes like 30 bits.

Prem: I was not even alive at those times lol

Wethje: Then professionally in Fortran, then C++, then retired.

Sheen: Well, retired from programming. He still drives school buses and teaches substitute math.

Clock: People can’t really retire in this day and age anymore.

Stills: His said his worst career move as a programmer, was aging.

Burkholder: I only program and design fonts and such as a hobby. :3

Reineck: I work for substandard wages at a startup in the hope that it pays off in millions because I own stock

Reineck: But tbh it doesn’t seem super likely

Pinedo: Is there a way to just dump a javascript function as plaintext on a page, in addition to being able to execute the script, without having the code twice in the source?

Reineck: You can use someFunction.toString to get a string representation of it

Griesbaum: Im modeling out a referrals system that gives users a dynamically generated “place in line” based on their referrals https://gist.github.com/Griesbaum/709a89afd23e804ed194

Griesbaum: Should i be using a counter cache? i wish there was a simple way to add this in mongoose like there is in rails :

Hemani: Thanks zomg, if my script is up in my head, how do i execute the function.toString somewhere in the body? I know that’s a basic question. but today is the day I learn javascript

Reineck: Same way as you’d execute it in the head :

Reineck: Although I don’t see why you’d need to put it in body

Ozley: Is it possible to know the argument names of a function before calling it?

Nishio: Why do you need to know what the function calls its arguments?

Citro: I’m working on a command framework, and I’d like to be able to p*** a single ‘data’ object with what might have arguments in

Vanliew: So if a function says doSomethinga, b, and the command has received a data object with {a:’foo’, b:’doo’} it will order the arguments correctly before calling the function from the command

Nishio: Dcholth: everything i’m seeing says no. you’ll need some other way to declare the API

Ernspiker: I think I found I’m looking for on Stackoverflow

Nishio: The arguments object is deprecated

Griesbaum: Any ideas on my counter cache question : ?

Muff: Pardon me? arguments in functions?

Opunui: Arguments.length, arguments0, etc.?

Vafiadis: Neither the arguments object nor using an “options” object as an argument is deprecated in JS

Vafiadis: Dcholth: “named parameters” using an object with a, b, etc basically make the “order” irrelevant – objects don’t guarantee order in pre-ES6, but they’d be accessed by name anyway. to achieve that kind of resulst you can simply do function someFuncargs { var a = args.a, b = args.b, etc; }.

Vafiadis: In ES6 you can do a neat bit of destructuring to make this even easier

Vafiadis: But that kinda destructuring isn’t supported on many engines yet, unless you’re using babel

Holla: Vafiadis: I found what I needed here http://stackoverflow.com/questions/1007981/how-to-get-function-parameter-names-values-dynamically-from-javascript

Borchers: Thanks for your help zomg, i think i figured it all out

Justak: It is. but its what I need

Vafiadis: Dcholth: usually you wouldn’t want to do something like that unless you’re doing some kind angular-style DI

Vafiadis: And even angular recommends not doing that, but instead annotating the DI so it isn’t relying on that