HNHacker News
TopNewBestAskShowJobs

jQueryIsAwesome

903 karma · joined September 10, 2011

@ivanca at twitter
submissionscomments
jQueryIsAwesome··on Diablo in JavaScript
Broken argument; flash is way too slow compared to the current version of Canvas; recently I made a full conversion of flash to canvas (was painful but) the performance is outstanding and the ability to interact natively and play nice with the DOM is invaluable.
jQueryIsAwesome··on Diablo in JavaScript
So I guess I can't talk about the DOM; many functions are just an API for it; and canvas is just an API for drawing accelerated by the CPU; so... Javascript is nothing and nothing can be blamed on it?
jQueryIsAwesome··on Diablo in JavaScript
Even older, perfect for devaluing JS! The similarity is truly shocking.

http://en.wikipedia.org/wiki/File:CUcollaboration.gif

http://www.teknoblog.com/wp-content/uploads/2012/07/gmail-go...

jQueryIsAwesome··on Diablo in JavaScript
No -webkit- specific code in sight and the console shows no error; the worst kind of bug.

Edit: I found it; It is using the event property offSetX instead of a cross-browser property; if the developer or someone else want so fix: http://stackoverflow.com/questions/11334452/event-offsetx-in... [Line 151 in diablo.js]

jQueryIsAwesome··on Diablo in JavaScript
The code is pretty much open (even commented and well organized) and It can fairly easy be changed to SVG to support pretty much every modern browser. Open enough for me.
jQueryIsAwesome··on Diablo in JavaScript
Yeah, only now with javascript we can transmit HD videos in realtime via webcam with Chrome or Firefox, just like in 1997... no wait... the cherry picking of an example went wrong on that one. But maybe we can still devalue Javascript by saying HD videos is a separate thing and that speed connections is more important than Javascript in that example?
jQueryIsAwesome··on Diablo in JavaScript
He is sucking someone's else popularity! What an evil and selfish mind he has!
jQueryIsAwesome··on Diablo in JavaScript
This works pretty nice in the most used browser in the world (Chrome last release), that is a win in my book.
jQueryIsAwesome··on Pixel Art Tutorial
Interesting.
jQueryIsAwesome··on Show HN: a web-based xkcd-style comix editor
This little comic I "created" some time ago is never going to be so relevant again so here it is [inmature humor ahead]: http://i.imgur.com/EnXc9e9.jpg
jQueryIsAwesome··on The Chrome Javascript editor can do hot swapping
And recently from the settings menu (low right corner) it also can change the user agent, reported resolution, the geo-location and emulate touch events. Chrome inspector is really something else.
jQueryIsAwesome··on Lung Cancer and the Power of Suggestion
Or you know, people who have smoked is more likely to have kids with cancer or who where second-hand smokers at an age they can't remember now.

Also, campaigns against brest cancer had an exponential grow too but somehow the rate of breast cancer is about the same, or do your hypothesis includes lungs being more affected by perceptions than any other organ?

jQueryIsAwesome··on Pixel Art Tutorial
24 but that's not a honest question. I have played and completed hundreds of old adventure games (almost all of them look pixelated) including Monkey Island 1, 2, 3 and 4 in their original graphics using a DOS emulator; the first two are the more pixelated and are far better than any other of the following but there is a reason why they decades later recreated the first one using less pixelated graphics. Those were the best for the engaging characters, puzzles and comic situations and it has little to do with the low resolution they have.
jQueryIsAwesome··on Pixel Art Tutorial
No, I would just fire the artist and hire someone who is not found on making thinks that look like GIFs, like: http://72dpi.cn/wp-content/uploads/2011/01/Ryohei-Hase-599x6...
jQueryIsAwesome··on Pixel Art Tutorial
That's what they are pretending; not that it has none.

And this is for games where immersion is one of the priorities; those micro-squares just make think that my monitor may be using some low resolution settings and doesn't help a little bit to the credibility.

jQueryIsAwesome··on Pixel Art Tutorial
If you can't avoid the "pixel" part and go straight to the "art" my eyes would appreciate it. If I want nostalgia I will play games that look pixelated for technical limitations now in the past, not for willingly decaying graphics pretending it has some artistic value.

Even after just using a little bit of median filter it looks better: http://i.imgur.com/P4Dr9Kr.jpg

jQueryIsAwesome··on Namespaced Gists
yep: https://gist.github.com/2927038 used to redirect here: https://gist.github.com/doubleotoo/2927038 (in Google results)
jQueryIsAwesome··on Tom, Dick & Harry
> You'd think a reasonable math person--or any halfway competent programmer--would not throw in a call to math.random in the definition of their monoid!

Yeah, just pick 'a'; if he was in the database before 'b' chances are that he is the one who has been with the company for the longest time; and if that's a lie then is just as random as math.random anyway.

jQueryIsAwesome··on How A Pull Request Rocked My World
I do something a little bit similar with DOM interaction in JS, for example button ".btn_pdf_docs" shows all ".pdf_docs" elements. I consider the code to implement this more readable than a bunch of events binding.
jQueryIsAwesome··on Shapecatcher: Draw the Unicode character you want
It's not every day that the top comment on reddit.com/r/funny is also the top comment on Hacker News.
jQueryIsAwesome··on Someone got the natural gas report 400 ms early
With a very corrupted definition of "usable".
jQueryIsAwesome··on Mark Cuban Is Endowing A Chair To ‘Eliminate Stupid Patents’
True, it haves to be a big country... like China; I want to see them stomp that.
jQueryIsAwesome··on How I Failed, Failed, and Finally Succeeded at Learning How to Code
There are fixed-sized intArrays and buffers in JS nowdays.
jQueryIsAwesome··on Why not make your URLs responsive?
Well, you can rotate the words if it's really that long: http://fiddle.jshell.net/fuDSb/10/show/light/
jQueryIsAwesome··on How I Failed, Failed, and Finally Succeeded at Learning How to Code
Is popular because is the only language allowed in the browsers; any other assertion is purely speculation. Just be glad is not COBOL or C (imagine any amateur's code causing memory leaks in the browser...)
jQueryIsAwesome··on Why not make your URLs responsive?
I want responsive favicons... thing is; I'm not joking; it would be very useful if every site had a 128px * 128px and 640px * 640px versions of their favicons (logos?).
jQueryIsAwesome··on Turn your browser into a notepad with one line

    data:text/html,<html><script>window.onload=function(){var a=document.body;a.addEventListener("keydown",    	function(b){if(b.ctrlKey&&83===b.which){document.location = 'data:text/html,' + document.childNodes[0].outerHTML;b.preventDefault();}},!1);document.title= document.body.innerText.replace(/\n[\s\S]+$/," - ")+new Date().toString();};</script><body contenteditable></body></html>
With this you can save using the URL!

Just press Ctrl+S and use the browser history to access it later! And this means it also haves a pseudo-version-control-system included! For easy access the first line in the text becomes the title.

In coderwall: https://coderwall.com/p/xh9u3w

jQueryIsAwesome··on Turn your browser into a notepad with one line
In unrelated news coderwall.com really needs good syntax highlighting. Is called CODERwall for God's sake.
jQueryIsAwesome··on Javascript Cryptography Considered Harmful
To avoid some of the bad you can put this before the other Javascript files because that way you don't destroy event listeners.

Also I changed "document.all" for "document.body.childNodes" that is cross-browser and can't be compromised.

jQueryIsAwesome··on Javascript Cryptography Considered Harmful
Yes you can be sure; using an iframe + innerHTML because the later one is not a function and can't point at one or can be defined any other way and the same goes for its parent objects.

    document.body.innerHTML += "<iframe></iframe>";
    document.body.childNodes[document.body.childNodes.length-1].contentWindow.crypto.getRandomValues;
And please don't talk about how the JS engione of the browser can be compromised too; I know that but here we are aiming for practical applications not a philosophical debate about how everything is just an illusion.
← PreviousPage 4 of 20Next →