« first day (1679 days earlier)      last day (3267 days later) » 

12:00 PM
@GNi33 sizzle (if that is still the selector engine jquery uses) is pretty fast.
 
no when i alert the json variable as whole it works fine @JanDvorak
 
Whats the real need of require.js?
 
did you forget to parse?
 
I mean it gives the correct variable and its value
how do I do that?
 
@Ant's Module loading?
 
thanks
@JanDvorak
 
ooh I love empty pings
 
But thats the only reason? I'm using module pattern, plain old with out any libs, things works. Was thinking why require.js helps me. Because one of my team member said, as your module grows, things can became an nightmare
@RoelvanUden
 
And this is minor but it requires you to call one more layer of unnecessary functions to call something that can be done using native Javascript functions.
When that 1 more layer of unnecessity accumulates, it is a pretty big chunk of resource waste on users' side.
for example
function jQueryMagic(arg){
return javascriptNativeStuff(arg);
}
 
wait, you can use native DOM-Api to do what jQuery does? noooo
 
12:03 PM
@Ant's Because when your modules grown, things can become a nightmare. Really. You're probably doing in-browser development and poluting the global scope with all the crap you tag on. Module loaders isolate your code (usually one file = one isolated scope), enable simpler references, allow unit testing much easier, and enable bundling and reuse.
 
what's your point?
 
@AwalGarg is this what you expected? : code.google.com/p/chromium/issues/…
 
jQuery is a abstraction layer, made necessary in the dark times of different implementations of the native API and every browser introducing it's own set of bugs.
 
@Julo0sS > What is the expected behavior?
Allow Xhr
what?
 
Additionaly, it gives you an API for common functions needed in every day frontend - web development and it's maintained by a lot of knowledgeable people to make it work consistently on a wide range of browsers
 
12:05 PM
Where did XHR come in here?
 
of course you can write all this stuff on your own
 
If you do a quick benchmark test between
//loop 20000 times
javascriptNativeStuff(args);

and

function jQueryMagic(arg){
return javascriptNativeStuff(arg);
}

obviously the first one saves you some resources
 
with this implementation... no, it doesn't
 
@EnglishMaster What's the point you're trying to make?
 
@RoelvanUden What do you mean by "in-browser development and poluting the global scope with all the crap you tag on". Because I'm doing this:
 
12:07 PM
@AwalGarg problem here is that xhr queries are blocked no?
 
var obj = (function(){
    var private = "private"
    var obj = {
       testFn : function() { console.log(private) }
    }
    return obj
})()
 
I'm just trying to discuss
about jQuery
 
in what way me populating the global namespace?
 
@Ant's you're still exporting obj
 
@Ant's If you do this in the browser, obj is now in the global scope.
window.obj
 
12:08 PM
@Julo0sS there are no xhr requests here. XHRs are meant to be blocked on different ports anyways, that's how Same origin policy works, but not WSS. Remove XHR and put WSS instead.
 
cannot edit :(
 
@RoelvanUden: So thats again an issue? In what way its going to create problems?
 
@Julo0sS put a comment instead, and ask a moderator to edit for you.
 
@Ant's What if you have two files that both define obj? It gets redefined, and everything dependent on the existence of obj now has a broken reference and will explode as soon as it runs.
Remember kids; Globals are bad.
 
sometimes I want my stuff to be acessible
 
12:10 PM
@RoelvanUden: So how does requireJs solves this? It binds to its local scope? And we can get the module by calling some API on it?
 
Example naming collision when using globals: var top = positionTop(element); // overwrote window.top
 
@AwalGarg theres no way to ask mod to edit anything, this issues system is ... jfqsm fdshj qh :(((((
 
@AwalGarg I thought top was unwritable?
 
12:11 PM
wth
 
@JanDvorak right, what I meant is, you would think you overwrote it, thus producing buggy code.
 
Raynos had another pretty long gist about how to shim instead of using jQuery, can't find it right now
I personally like to use jQuery for what it is, I understand if people don't like it though
 
@Ant's Essentially it converts your file into a function, runs it, which has its own scope of course, and caches the exports and exposes that. The result is simply that your code cannot (easily) throw crap on the global scope. Isolated code, predictable, easy to maintain and debug. Less worries, more fun :P
 
@Julo0sS just put a comment asking mods to edit it for you.
 
12:13 PM
I commented. Wait & see... ^^
 
> Dear mods, my overlords, may faith shine on you if you accept thy plea of editing the holy issue above to replace Xhr with the word "wss".
 
@AwalGarg lol
didnt write it this way, but meaning is the same :P
 
@GNi33 Yes chatroom on SO but i've just realised have to have 100 reputation :)
 
@RoelvanUden: Thanks that helps. And I have my last query. Currently using the plain old module pattern the one issue I'm facing here is, I couldnt able to mock the private variables (hence its inside the closure) so I'm forced to have a setter atleast for testing. By any means this problems is been solved by require.js?
if so I would jump out of my chair now! :)
 
@Ant's Sorry, I didn't quite follow the question. Can you elaborate?
 
12:18 PM
@Ant's no, you can't solve this anyhow. Improve the design itself and passing parameters instead of setting them in helps.
instead of doing function () { var local = new foo(); ... } do function (local) { ... }(new foo)
(pseduo code ofc)
 
@BenFortune blame your face
 
Any suggestion for creating "global edit" feature for Wordpress posts like in Stackoverflow questions?
 
user1994804
Hi Guys, Could you plz take a quick glance at something for me? I'm in way over my head and just need a lil boost so I can get this working, then go thru it backwards for a few days if necessary until I understand what's going on here
 
@rlemon That was so uncalled for
 
user1994804
Plz take a look at this
 
12:20 PM
I called for it
 
Fight me
 
Bite me
 
k bb
 
var obj = (function(){
    var private = "private"
    var obj = {
       testFn : function() {
             if(private == "test")
               console.log("operation A")
             else
                console.log("Operation B")
    	}
    }
    return obj
})()
 
Yeah, let's not do that again.
 
12:21 PM
but
 
user1994804
Lots of RUDE people
 
1 message moved to JS trash
don't stir the pot
 
user1994804
Its unfortunate
 
in this code say I want to test testFn, for sure I need to mock private , but I cant , so I have forced to use setter for private variable @RoelvanUden
 
user1994804
But if you guys could take a look here
 
12:22 PM
room jokes around with eachother -- in comes random person, "you guys are so rude"
 
user1994804
Oh Wait...
 
C# is hard
Trying to pinvoke ffmpeg
 
user1994804
I just thought of an easier way you guys could help
 
@Ant's it's private don't mock it.
 
12:22 PM
ffmpeg is hard
well, not fun.
 
Angular question: Is there a way to add some delay (2-3sec) to ng-show?
 
user1994804
Instead of all that lemme try it like so
 
user1994804
just a sec
 
ff?
firefox mpeg?
 
@phenomnomnominal: yeah I know its a design problem, how can I solve it
 
12:23 PM
obviously not
 
@NickDugger you've never heard of ffmpeg?
FFmpeg is a free software project that produces libraries and programs for handling multimedia data. FFmpeg includes libavcodec, an audio/video codec library used by several other projects, libavformat, an audio/video container mux and demux library, and the ffmpeg command line program for transcoding multimedia files. FFmpeg is published under the GNU Lesser General Public License 2.1+ or GNU General Public License 2+ (depending on which options are enabled). == History == The project was started by Fabrice Bellard (using the pseudonym "Gerard Lantau") in 2000, and has been maintained by Michael...
 
Never heard of it, yeah
 
@AwalGarg: That is a good idea. However I should try them.
 
audio/video shit
 
freely fuckable mpeg
 
12:24 PM
your mom?
 
user1994804
After storing some minor data in JS localstorage I can make it output the entire array as I was gonna show yall
 
your grandmom
 
user1994804
But Fast Fwd Im retrieving it like so: var retrievedObject = localStorage.getItem('SellerBuyerLocation');
 
Ubuntu users -> ever notice on a new ssh session if you type quickly in the first few seconds it drops the connection?
 
user1994804
and I can output it all like so
 
12:25 PM
@rlemon no
 
guys... angular 2 seems pretty good... None of Angular 1's bullshit (angular.controller, ew)
 
@rlemon no
 
user1994804
<div id="TestUserData"></div>
<script>document.getElementById("TestUserData").innerHTML = retrievedObject;</script>
 
damn, happens to me all the time.
doesn't matter what server I ssh to
 
Wait, ubuntu server or desktop?
 
12:26 PM
desktop
 
I always use putty to an ubuntu server
 
user1994804
and that cranks out the whole array right before my eyes but how do I get only what I want?
 
I use putty when I'm on windows
 
@YourAdrenalineFix Loop through the array and append it?
 
user1994804
Ive tried innerHTML = retrievedObject.something and Ive tried innerHTML = retrievedObject->something
 
user1994804
12:27 PM
@BenFortune you're wayyy ahead of me
 
the latter is c++ism
 
That would make it an object, not an array
 
@rlemon sshed to DO VM just now and also set xsel to type stuff for me (since it will likely type way faster than us), but no connection drop for me.
 
You got an example of retrievedObject?
 
user1994804
The only way I know is starting with where Im at, throwing it all out in front of me, then working backwards
 
user1994804
12:28 PM
Yes @BenFortune
 
user1994804
I'll get that for you in one second
 
user1994804
I'd just like to explain
 
Uncaught NoModificationAllowedError: Failed to execute 'removeProperty' on 'CSSStyleDeclaration': These styles are computed, and therefore the 'visibility' property is read-only.
http://localhost:2809/Undefined Failed to load resource: the server responded with a status of 404 (Not Found)
 
@YourAdrenalineFix then go backward...you will go forward... kidding
 
user1994804
I have studied probably every tutorial on JS, AJAX, PHP
 
user1994804
12:30 PM
ha ha
 
How do I make the style object editable?
 
@Jonathan seriously?
 
> studied every tutorial
 
you just linked up localhost
 
user1994804
i know but Im a slow 2 finger typer so bear with me
 
12:30 PM
@Jonathan you are not allowed to modify computed style object
 
the internet is hard
 
@rlemon I think he just copied the error from the console
 
ahh
fun fact: the StyleSheet api is read-only as well
which is very very stupid
 
To prevent XYing: I'm trying to style an input in an iframe the same as the input would look in the parent of the iframe
 
user1994804
I have studied probably every tutorial on JS, AJAX, PHP on the www over the past few years but Im now at the point where I just need more experience and the help you guys provide is very much appreciated
 
12:31 PM
So I'm creating an input, calcing style and applying it to the css rule in the iframe
Does that make sense?
 
user1994804
<---winded
 
But atleast most stupid DOM parts throw a readable error unlike non strict mode js which fails silently
 
Wait, years?
 
@Jonathan read with getComputedStyle write with elm.style.Blah
 
I don't have access to elem.style at that point
 
user1994804
12:32 PM
Yep @BenFortune . Ok , Take a looksie here
 
so I'm writing css = "input[type=text] { " + style.cssText + " }";
 
@Jonathan why not?
 
user1994804
below the fold, you'll see 2 shipping rates
 
user1994804
click "More Info on This Rate"
 
12:33 PM
legacy code ^^. Maybe I should fix it
 
user1994804
when you get to the next page you'll see what Im storing and outputting
 
user1994804
I know i know... Im working off the live site
 
Lol really.
 
user1994804
legacy is all I know
 
@YourAdrenalineFix Why don't you post a question on the main site?
 
user1994804
12:34 PM
Im blocked
 
user1994804
go figure huuh?
 
user1994804
lol
 
user1994804
Problem there is there is no such thing as defending ones self
 
user1994804
even when you're in the right (like I always am)
 
what
 
12:36 PM
Nope
 
@AwalGarg We're creating the input with document.write -.-
 
> spends years studying php and ajax
is always right
 
user1994804
All I really need to figure out is how to not output the whole object and use just the values I need
 
are you talking about SellerBuyerLocation?
Also
 
user1994804
@NickDugger Yep, Always right in the issues Ive defended. When you study things that long you know little useless details noone else does
 
12:38 PM
> detail.php:268 Uncaught SyntaxError: Unexpected token {
@YourAdrenalineFix You're an arrogant chap, aren't you?
 
user1994804
but that has never beeen the source of conflict. That is people actling like jerks
 
I thought I had an ego
 
user1994804
and me reating
 
user1994804
reacting
 
That's not how the world works
 
user1994804
12:39 PM
@NickDugger Yes, SellerBuyerLocation
 
@YourAdrenalineFix How are you retrieving it from localStorage?
 
user1994804
Whats not how the world works?
 
Because as of now, it's stored as JSON, you'll need to parse it once you get it
 
user1994804
Just a sec @NickDugger Im trying to keep up with u my frd
 
then you can use dot/bracket notation to get values from it
I'm not your frd, bdy
 
12:40 PM
Nope, definitely not going to rewrite that now...
How do I remove the visibility property from the styleDeclaration?
 
user1994804
@NickDugger I'm retrieving it like so
 
user1994804
var retrievedObject = localStorage.getItem('SellerBuyerLocation');
 
change that to var retrievedObject = JSON.parse(localStorage.getItem('SellerBuyerLocation'));
 
user1994804
Then outputting what you might have seen on the site with
 
I don't need to know what you're writing to the page
 
user1994804
12:41 PM
<div id="TestUserData"></div>
<script>document.getElementById("TestUserData").innerHTML = retrievedObject;</script>
 
all you need to know is that you have JSON stored in locaStorage
and you need to parse it
 
if(window.addEventListener) {
    document.getElementById('').addEventListener("click", btn1func, false);
} else if (window.attachEvent) {
    document.getElementById('').attachEvent("onClick", btn1func);
}
wat
 
just... pls
 
user1994804
Ok, I just wanted to show you (incase it helped you) how I was ouputting the entire variable currently
 
@BenFortune IE8 compatibility code
 
12:43 PM
@JanDvorak Yeah, but he's adding events to null.
 
user1994804
@BenFortune that's some commented out code for a future project
 
@Jonathan your privileges to write javascript are revoked.
 
ah. not good
 
Some day, some day
Just not today...
 
user1994804
To allow all this to work in <=IE8 Thank You @JanDvorak
 
12:44 PM
If your website works in ie8, you wasted your time
 
user1994804
Ain't I nice when being nice to?
 
user1994804
see how that works?
 
@YourAdrenalineFix sure. Keep it up, buddy
 
user1994804
Just a sec @NickDugger Im gonna add the parse bit
 
user1994804
12:45 PM
@JanDvorak ALWAYS
 
user1994804
Disclaimer: as long as I dont get kicked in the groin upon entry
 
user1994804
;)
 
*don't
 
If someone gives you trouble, just ask them what you did wrong and apologize
 
donut
 
12:47 PM
@Meredith how do I trouble you more? plz say :D
 
Do you know what chemists do with extremely volatile compounds?
 
@Meredith He has a history of being extremely entitled. Today is going well, though. Ice cream may be in order
 
@JanDvorak hide them in colleagues mailboxes?
 
@AwalGarg I'm about to murder you
 
hi @rlemon
how is canada
 
12:48 PM
1 min ago, by Meredith
If someone gives you trouble, just ask them what you did wrong and apologize
 
That rule doesnt apply to bloop bloop bloop bloop bloop bloop
 
@KendallFrey did you leave?
 
:D
 
and how
 
where are you?
 
12:49 PM
@KendallFrey is in Ireland, dancing with penguins
 
It's 5:49 PM here :)
@rlemon Tajikistan
 
What are you doing in tajikistan
 
why?
 
what the hell are you doing in tajikistan?
 
I think it's time to leave work any minute now
here for business (and some fun, why not)
 
12:50 PM
@AwalGarg BTW, I didn't write that...
 
Is Tajikistan a place, or more of a state of mind?
 
both
 
I like the stickies today :-)
 
@Jonathan You are not editing it out, though. Much greater of a sin.
@ElliotBonneville managed to find the listener still? ;)
 
@AwalGarg :p not yet
then again I haven't looked
since last night.
 
12:51 PM
lol good luck
 
user1994804
Hey @NickDugger It works, (I think) but now Im getting [object Object]
 
@AwalGarg As the saying goes here, no good deed goes unpunished.
 
Oh boy
 
!!define no good deed goes unpunished
 
user1994804
12:52 PM
@Jonathan As the saying goes here, no good deed goes unpunished ROFLMAO
 
@YourAdrenalineFix That's because you're writing the Object as a string; that's what happens. Try doing yourObject.someProperty
 
@AwalGarg no good deed goes unpunished Beneficial actions often go unappreciated or are met with outright hostility. If they are appreciated, they often lead to additional requests.
 
user1994804
I LOVE You!!!
 
TIL a weird stupid "saying"
 
user1994804
OMG!!
 
12:53 PM
Oh well, @AwalGarg, guess FF has Chrome beat on that one. Not that I've ever been set back by it
:p
 
GMO
 
user1994804
You just opened the door WTF open for me to conquer the world
 
lol
 
I still like Chrome better though, it's not as Firefox-y
 
12:55 PM
@ElliotBonneville try editing and resending a request from chrome :P
 
Just try to profile any bundled code with the chrome profiler, you will need a lot of good luck with that really.
 
Bundled code? As in compressed?
 
yes, concatenated minified code that goes into production, which is much more practical to profile.
 
you know I could just go and install Firebug on Chrome
 
1:00 PM
spy-js
 
Firebug is not FF's dev tools lol
 
I'm grasping at straws here ;_;
 
Chrome dev tools still do everything I need and more
FF interface is ugly and I don't like it
 
FF does sound really nice, if you need to do those things. I don't, so Chrome is nice for me
 
@rlemon true story
 
1:01 PM
and yeah, Chrome's UI is nicer
 
Also, chrome in general feels faster. And chrome dev tools are a bit more stable than FF ones.
 
user1994804
@NickDugger You Sir Helped Me Immensely and I Thank You For Your Help
 
yeah. also the other reason I like Chrome dev tools is that Chrome is my main browser already, so.
 
@YourAdrenalineFix ok, Jaden Smith
 
I don't like FF as a browser but its tools do sound more powerful :( so conflicted. I think I'll stay with Chrome
 
1:04 PM
I just don't have much problem in changing tools and adopting to new stuff, so it was easy for me to switch. But they are not for everyone and thus I don't bark at every second person using chrome for dev...
 
yeah, I haven't found chrome dev tools lacking in any way
 
chrome vs FF is pretty moot - they both are good modern browsers with excellent built-in tooling. it all comes down to what small feature A supports that B doesn't that is important to you
if anyone says one is better for dev than the other, they are blowing smoke out their ass
 
is ff still heavier, process-wise?
 
@rlemon Good points
 
haven't bothered to look in a while
 
1:05 PM
chrome is a ram destroyer
 
well, thanks for the info, @AwalGarg :-)
 
np
 
Chrome at least doesn't force smooth scrolling; so there's that
 
I wrote a userscript for that :D
 
I'm sure you did, robert
 
1:08 PM
my boss likes smooth scrolling. so I installed it on his chrome so he doesn't bitch when he tests the products on chrome
 
(did you get that little hint of condescension?)
Smooth scrolling is only good with a touch mouse
 
@rlemon you're joking, right?
 
not sure if I feel sorry because your boss needs smooth scrolling or because he complains about not having it, @rlemon
 
@GNi33 nope, lemmy get the code.
(function(cont) {
    "use strict";
    var maxScrollAmount = 36;

    function handleScrollWheel(event) {
        if (!event.wheelDelta) {
            return;
        }
        var scrollAmountX = Math.min(maxScrollAmount, Math.abs(event.wheelDeltaX)),
            scrollAmountY = Math.min(maxScrollAmount, Math.abs(event.wheelDeltaY)),
            scrollDirectionX = event.wheelDeltaX < 0 ? 1 : -1,
            scrollDirectionY = event.wheelDeltaY < 0 ? 1 : -1;
        cont.scrollLeft += scrollAmountX * scrollDirectionX;
 
haha, that's brilliant
 
1:10 PM
tweaked to match his FF settings ofc
 
fun fact: you can disable smooth scrolling in FF. I disabled mine last year, and it syncs the settings everywhere and on reinstalls etc.
 
I don't like that FF caches input values -- makes debugging weird
 
I like Chrome's autofill functionality
 
1:25 PM
how much object oriented concept is required to properly write angularjs stuff. I know some basic stuff from java .. and I know about SOLID .. (a little) .. but still then when I look at my code or my partners code, I feel so upset
 
Angular has nothing to do with OOP. Angular 2 is a little different, though
 
@argentum47 "SOLID .. (a little)"
how can you know SOLID "a little"?
 
"Dystroy invited you to the room Trash Can"
is this where I belong?
:/
 
@FlorianMargaine like maybe he read about the concepts, didn't understand all the stuff. Or he understood the concepts but didn't apply them in code. Or applied them in code and failed. Or successfully applied them in code but code didn't turn out nice - so applied incorrectly. etc. etc.
 
1:42 PM
@FlorianMargaine because you don't have THAT much fiber in your diet, only a little ;)
 
So... in meteor, are you supposed to use this.error on publications and handle it on the subscription handler? I don't get what they want you to do
 
I'm 77% sure the question was rhetorical
 
Error 404 occured, I will call the maid (@Zirak)
Error 404 occured, I will call the maid (@Zirak)
 
!!listcommands
 
@AwalGarg 666, help, listen, eval, coffee, refresh, forget, info, listcommands, tell, afk, ban, unban, convert, define, doge, google, hang, jquery, learn, put..it..back...ლ(ಠ益ಠ)ლ, phucket, gtfo, moneycantbuylove, catmode, coffeetime, lifeban, stopmyself, instagram, kendallfrey, excited, manigga, meinneger, dgaf, infiniteriot, okay, feelsgoodman, fabulous, sausage, playerpimp, installjavascript, moarkittens, kendall, banana, kfc, uwot, nsfw, facepalm, somekittens, erase, fry, dudeism
hahastillhere, onebox, morecoffee, steve, whoosh, burn, woosh, roomowner, phony, really, inur, coffeescript,
Error 404 occured, I will call the maid (@Zirak)
 
1:49 PM
bah
FF needs a update anyways
!!info
 
@rlemon I awoke on Fri, 22 May 2015 13:49:44 GMT (that's about 19 seconds ago), learned 337 commands
 
I always hover over links before clicking on them
FOILED
 
cc @Loktar @FlorianMargaine
 
thats like, my favourite song
 
@rlemon happy Friday bro
 
happy friday @Loktar @rlemon #brolove
 
Everybody's Russian
 
kiss on the lips
 
happy Friday @FlorianMargaine
kisses
 
1:53 PM
open your mouth
I want your tongue
 
LOL
 
I didn't brush this morning
 
@FlorianMargaine I have read about it in wikipedia, I try to follow Seperation of Concerns but I haven't implemented much of O and L. so a little.
 
so forceful, I likes it.
 
happy Friday
 
1:58 PM
@rlemon lorempizza is crashing
:(
pls
 
@Loktar 2.9
 
fixed
 

« first day (1679 days earlier)      last day (3267 days later) »