Gentleman: Which is how node could protect against it trivially.
Kalinoski: Well no. you don’t NEED call
Gentleman: You need either call, or apply, or bind – but all three can be broken
Gentleman: I guess technically you could use setTimeout, depending on the implementation
Lewars: Rock, paper and scissors can all be dead. D:
Brashaw: Just state in the docs that your code requires unmodified prototypes. You can’t protect against everything.
Grew: New function{ return this; }.bind{ foo: 4 }.foo;
Fatigate: Except it produces the wrong result for that.
Hranchak: AllFurniture.forEachfunctionfurniturePiece { furniturePiece.coverWithnew Plastic; };
Gentleman: Saltarelli: yes, you can :-
Gentleman: Saltarelli: but most people aren’t willing to do that.
Adamo: Gentleman: Everything?!
Gentleman: Saltarelli: everything that happens *after* your code runs, yes.
Pangle: Well, after, yeah, true.
Gentleman: And you basically can’t protect against *anything* that runs *before* your code.
Gentleman: Such is the security model of JS.
Adelblue: My JavaScript humor is wasted. ;.;
Adside: Hey guys, i have a quick question. I have a search function on my site that uses window.find made with javascript. when i run it inside chrome it works but when i open it in a chrome extention i made it does not run. How is this possible, is it due to permissions?
Millimaki: A Chrome extension? Using Greasemonkey-style API?
Olowe: Though whether that’s reasonable is debatable. It probably is for published libraries.
Gentleman: Saltarelli: for any reusable code, i’d say.
Gentleman: Saltarelli: for an app, surely, you’re in control, so no.
Ends: Heroman: Saltarelli https://developer.chrome.com/extensions/getstarted
Scala: I’ve written extensions before.
Liff: I have a html shown inside my plugin but the JS does not run
Senay: Heroman: no its the source i used
Stahl: Can someone else help him? I’m feeling increasingly fatigued, which makes it harder to communicate in English.
Schierenbeck: Gentleman: Yeah, apps often contain reusable code. Company-wide code? Dunno. It’s a grey area for me. But it’s easily included in the do***entation if you opt out.
Kalinoski: Yeah I don’t know about the chrome extension problem
Kalinoski: Dankmeyer what do you mean it doesn’t run? does it throw an error?
Gentleman: Saltarelli: things not enforced in code aren’t enforced. do***entation is a nicely optimistic way to communicate things, but it’s useless if the code doesn’t ensure it.
Kahuhu: Gentleman: Code is useless if used incorrectly. You can’t byp*** people.
Cumbass: Kalinoski: its not there, the code is not executed
Keets: Hello, i want “antwoort” to be a global variable but outside of the function its always undefined, http://pastebin.com/BjGCrp5b could someone explain me, why?
Shry: Why isnt my rectangle object moving? http://codepad.org/XH6E5sGg
Mate: Libutti: ‘Hoisting’ is the name given to the mechanism whereby names defined with ‘var’ or function declarations see !fe are made available throughout their scope, even before the declaration is encountered textually. Beware: though the *definition* of a variable is available, its value if given will be undefined until the var declaration is encountered or the variable is otherwise ***igned to.
Rodolph: Phale you need to redraw
Mate: Libutti: An “immediately invoked function expression” is an expression that both creates and calls a function. As with any function call, a scope is created. “function { /* . */ }” is the most common form. For more info: http://benalman.com/news/2010/11/immediately-invoked-function-expression/
Cales: Ankr: oh right, Im supposed to put the draw function in the onmousemove event