John Resig - Bulk Vote for Reddit, Digg, and Hacker News (4)
share
digg
by
John Resig (114)
on
John Resig (109)
22 hours, 26 minutes
ago
permalink
Update: Ok, so this is more of an issue than I originally surmised - apparently it violates the Terms of Service on a couple sites, especially Digg. I've removed Digg support and may have to take the script down at some point. Sorry everyone! Last weekend I decided to play around with the new Ubiquity extension for Firefox, building a command. The command is called 'vote' and it gives you the ability to bulk vote ...
John Resig - JavaScript Performance Rundown (33)
share
digg
by
John Resig (114)
on
John Resig (109)
1 day, 21 hours
ago
permalink
A new JavaScript Engine has hit the pavement running: The new V8 engine (powering the brand-new Google Chrome browser). There are now a ton of JavaScript engines on the market (even when you only look at the ones being actively used in browsers): JavaScriptCore: The engine that powers Safari/WebKit (up until Safari 3.1). SquirrelFish: The engine used by Safari 4.0. Note: The latest WebKit nightly for Windows crashes on Dromaeo, so it's passed for now. ...
-
pseudoTechie said:
FF seems to be still good enough to google chrome. So much attention to JavaScript these days
Google Chrome Process Manager (21)
share
digg
by
John Resig (114)
on
John Resig (109)
3 days, 14 hours
ago
permalink
About the just-leaked Google Chrome browser: Google also say they’re using a “multi-process design” which they say means “a bit more memory up front” but over time also “less memory bloat.” When web pages or plug-ins do use a lot of memory, you can spot them in Chrome’s task manager, “placing blame where blame belongs.” If this is true and there's a process manager which allows you to see how many resources are being consumed ...
-
djspark said:
agora, todo mundo aprendendo javascript direitinho, né? :)
Open Web Podcast: Anne Van Kesteren (1)
share
digg
by
John Resig (114)
on
John Resig (109)
5 days, 9 hours
ago
permalink
This week we interviewed the, quite prolific Anne van Kesteren on CSS, XHR, and other Web standards. A breakdown of the contents of the interview, by Dion: Anne van Kesteren is an Opera Software employee who is deeply involved in the standards community. Just take a look at his page on the WHATWG site and you will see the many specifications that he is actively working on, such as: access-control XMLHttpRequest XMLHttpRequest2 cssom-view css3-mediaqueries He ...
John Resig - How JavaScript Timers Work (2)
share
digg
by
John Resig (114)
on
John Resig (109)
1 week, 1 day
ago
permalink
At a fundamental level it's important to understand how JavaScript timers work. Often times they behave unintuitively because of the single thread which they are in. Let's start by examining the three functions to which we have access that can construct and manipulate timers. var id = setTimeout(fn, delay); - Initiates a single timer which will call the specified function after the delay. The function returns a unique ID with which the timer can be ...
Degrading Script Tags (22)
share
digg
by
John Resig (114)
on
John Resig (109)
1 week, 1 day
ago
permalink
One thing has always annoyed me about the script tag. Script tags that reference external resources (via the src attribute) are no longer able to execute script embedded within the tag itself. It doesn't make sense to me that we're forced to write: <script src="some-lib.js"></script> <script> var foo = use_some_lib(); foo.do.stuff(); </script> when this is so much more elegant: <script src="some-lib.js"> var foo = use_some_lib(); foo.do.stuff(); </script> Only one tag - and the semantics would ...
John Resig - Processing.js (13)
share
digg
by
John Resig (114)
on
John Resig (109)
1 week, 4 days
ago
permalink
Demos below! As a sort-of reverse birthday present I've decided to release one of my largest projects, in recent memory. This is the project that I've been alluding to for quite some time now: I've ported the Processing visualization language to JavaScript, using the Canvas element. I've been working on this project, off-and-on now, for the past 7 months - it's been a fun, and quite rewarding, challenge. The full scope of the project can ...
TraceMonkey (66)
share
digg
by
John Resig (114)
on
John Resig (109)
1 week, 6 days
ago
permalink
I've been waiting to blog about this for a long time now. A fantastic new improvement to Mozilla's JavaScript engine (SpiderMonkey) has landed. Code-named TraceMonkey this engine utilizes a techniques, called trace trees (PDF), which adds just-in-time native code compilation to SpiderMonkey. A major goal of the project has been to set JavaScript up to compete with natively-compiled code, rather than simply against other interpreters. This means that we're starting to see speeds that are ...
-
Sebastian Werner said:
Nice, but we still need to wait for IE to improve upon these new standards.
-
Jason Cartwright said:
This, is awesome
-
Daemach said:
Microsoft just can't keep up.
-
Sean said:
Javascript as fast as C. Mmmmmm. (Well, maybe not THAT fast, but still cool.)
Podcast #2, SXSW, Ninja Articles (4)
share
digg
by
John Resig (114)
on
John Resig (109)
2 weeks, 6 days
ago
permalink
Open Web Podcast #2 The second edition of the Open Web Podcast is now live. In this episode we brought on Brendan Eich and Arun Ranganathan (both of Mozilla) to discuss the recent changes that occurred in the ECMAScript 3.1/ECMAScript 4 processes that resulted in ECMAScript Harmony. This is a dense podcast - going just over an hour. The podcast is available as an mp3, ogg, an RSS feed, and on iTunes. Next week we're ...
Object.getPrototypeOf (11)
share
digg
by
John Resig (114)
on
John Resig (109)
3 weeks
ago
permalink
Historically one JavaScript property that's seen a lot of use (mostly due to its convenience) is that of __proto__. It's a quick-and-dirty way of accessing the original prototype property of the object's constructor function. For example, the following is true: "test".__proto__ === String.prototype // Another alternative, not using __proto__ // Only works when constructor isn't changed "test".constructor.prototype === String.prototype This feature has been codified in the upcoming ECMAScript 3.1 specification as a new method: Object.getPrototypeOf(object) ...
ECMAScript Harmony (11)
share
digg
by
John Resig (114)
on
John Resig (109)
3 weeks, 1 day
ago
permalink
There's been some turmoil in the world of ECMAScript. While many are - even, at least, vaguely - familiar with the development of ECMAScript 4 the devil is in the details. I've blogged about ES4 extensively in the past - and even did a speaking tour last fall educating developers about its details and implementations, however, a lot has happened since that time. The ECMAScript 4 specification development was very ad-hoc in nature (primarily tackled ...
-
Dexter.Yy said:
Brendan Eich (August 14, 2008 at 2:50 pm)@Question: Mozilla will continue to evolve JS toward JS2, which may even correspond to a 4th Edition. ES4 is a bit of a scare-word for some, and definitely overloaded or ambiguous, so we're using the ES-Harmony name for now. Whatever the Edition number and the future standards that emerge, we'll keep advancing JS in Mozilla's platform.Harmony means everyone on the committee is on the hook to work on not only 3.1, but a major successor (major meaning new syntax at least, probably stuff from JS1.7/1.8). In the best case this means vendors will compete to show prompt and faithful implementations of finished standards, as well as previews for testing draft-spec features.John Resig (August 13, 2008 at 8:09 pm)@David Brewer: That's definitely not clear. ActionScript 3 is based on a very different ECMAScript 4 draft, though - one from 1999. The current ECMAScript 4 work is an extension of that (supported by Adobe) and would've become ActionScript 4. However, the new ECMAScript 3.1 and Harmony proposals are not compatible with ActionScript 3/4, at all. The committee acknowledges this and it's unclear as to what will happen because of it.Dan Smith (August 14, 2008 at 6:51 pm)Brendan's comment pretty much nails where we're headed with ActionScript -- it's too early to know what will be in Harmony, but Adobe will track the specifications and likely implement what doesn't conflict. But no promises until we know what's coming. And we'll absolutely not be pulling classes, packages, etc out of ActionScript.@Question: Harmony doesn't change our working relationship on Tamarin at all. Tamarin can support multiple language variants -- it was already going to support SpiderMonkey(JavaScript) and Flash Player (ActionScript).
Tracking Firebug Performance (11)
share
digg
by
John Resig (114)
on
John Resig (109)
3 weeks, 3 days
ago
permalink
Firebug 1.2 final is set to be released sometime within the next week or two which means that our goals for Firebug 1.3 need to be pretty clear at this point. Last week the Firebug Working Group convened at Google to discuss the goals for the upcoming release. In taking a step back and looking at what was most important one thing was quite obvious: The stability and performance of Firebug needs to be improved. ...
John Resig - DOM DocumentFragments (43)
share
digg
by
John Resig (114)
on
John Resig (109)
1 month, 2 weeks
ago
permalink
I was playing around with DOM DocumentFragments recently, in JavaScript, seeing what I could make with them. Roughly speaking, a DocumentFragment is a lightweight container that can hold DOM nodes. It's part of the DOM 1 specification and is supported in all modern browsers (it was added to Internet Explorer in version 6). In reading up on them I came across an interesting point, from the specification: Furthermore, various operations -- such as inserting nodes ...
-
mca said:
DocumentFragments - sweet!
-
Puck said:
Koniecznie do przeczytania razem z komentarzami
-
Sheng said:
不过它无法用于XML
-
AlexCheng said:
使用DocumentFragment来提高DOM插入的性能,应该说早就为人所知了吧。cloneNode的使用以前不知道。
JavaScript Micro-Templating (33)
share
digg
by
John Resig (114)
on
John Resig (109)
1 month, 2 weeks
ago
permalink
I've had a little utility that I've been kicking around for some time now that I've found to be quite useful in my JavaScript application-building endeavors. It's a super-simple templating function that is fast, caches quickly, and is easy to use. I have a couple tricks that I use to make it real fun to mess with. Here's the source code to the templating function (a more-refined version of this code will be in my ...
HTML 5 data- Attributes (30)
share
digg
by
John Resig (114)
on
John Resig (109)
1 month, 3 weeks
ago
permalink
A new feature being introduced in HTML 5 is the addition of custom data attributes. This is a, seemingly, bizarre addition to the specification - but actually provides a number of useful benefits. Simply, the specification for custom data attributes states that any attribute that starts with "data-" will be treated as a storage area for private data (private in the sense that the end user can't see it - it doesn't affect layout or ...
-
Jady said:
平时如果需要用到类似的功能,可以按照这个标准来实现
Simple Extensions in Firefox 3 (2)
share
digg
by
John Resig (114)
on
John Resig (109)
1 month, 4 weeks
ago
permalink
It was fascinating to watch the unveiling of Firefox 3 last week. I'm pleased that, in some small way, my contributions helped to bring this browser out the door. First 24 hours: 8.3 million downloads, 69 downloads/second, 20 Gb/s Peak Transfer While I generally focus on issues tangential to JavaScript code, at Mozilla - like testing, performance analysis, specifications, standards, bug hunting, speaking, demos, and blogging - some of my code is live within the ...
-
past said:
This is excellent news for anyone writing Firefox extensions.
jQuery LiveSearch (5)
share
digg
by
John Resig (114)
on
John Resig (109)
1 month, 4 weeks
ago
permalink
A fun blog post popped up yesterday in which John Nunemaker ported a Quicksilver-style Live Search to jQuery. Taking a look at his code, I decided to have a little fun and re-port it to jQuery - trying to use the functional style that jQuery promotes. I think the end result is quite simple and elegant. The final code - compare with John's port: jQuery.fn.liveUpdate = function(list){ list = jQuery(list); if ( list.length ) { ...
BBC Removing Microformat Support (2)
share
digg
by
John Resig (114)
on
John Resig (109)
2 months
ago
permalink
Visit: BBC Removing Microformat Support After performing a number of usability studies (both on average users and users with screen readers) the BBC found that using the Microformat convention of <abbr title="...">...</abbr> to denote items like dates negatively impacted usability. This is a huge blow to the Microformats community. While this concern has been discussed for a while this is the first instance of a major corporation reneging on their previous Microformat commitment. As an ...
-
AlexCheng said:
这对于Microformat来说是个不小的问题。个人感觉,像hCal这样的microformat比较有用一点。确实不是很好理解。鼠标上去出一个问号,这个让人比较难理解。