D

Dean Edwards

dean.edwards.name · Personal blog · on HN since 2007

Dean Edwards writes about JavaScript tools and browser compatibility, including the Packer compressor, IE7.js, and base2.

What HN saysHN links it for Packer, ie7.js, and base2. Commenters mention Packer's base62 mode as an example of minification that looks like obfuscation, and note ie7.js supports up to IE9.
17HN people shared it
12linked it in comments
5stories submitted
7story points
5 years agolast shared
2007people per year2026

Most-shared posts

  1. 1
    Packer
    4 people · first shared 2008
  2. 2
    Make IE Behave (like a standards-compliant browser)
    2 people · 1 points · first shared 2007 · discussion on HN
  3. 3
    Ie7js update
    2 people · first shared 2010
  4. 4
    MiniWeb: an entire site in one JSON object
    1 people · 3 points · first shared 2007 · 1 comments on HN
  5. 5
    Notes on JavaScript Compression
    1 people · 1 points · first shared 2008 · discussion on HN
  6. 6
  7. 7
    Callbacks vs Events
    1 people · 1 points · first shared 2010 · discussion on HN
  8. 8
    CssQuery
    1 people · first shared 2022
  9. 9
    Homepage
    1 people · first shared 2009
  10. 10
    Busted
    1 people · first shared 2010
  11. 11
    Moz behaviors
    1 people · first shared 2012
  12. 12
    Base
    1 people · first shared 2010

What HN people wrote when they linked it

davecardwell · 2009-01-09
For learning the ins and outs of JavaScript I heartily recommend http://eloquentjavascript.net/ I’ve been meaning to make the time to try out a project using Dean Edwards’ [1] base2 library [2]. If you’re worried about being abstracted too far away from the underlying language this might be a good fit… Because this library is standards-based it means that you don’t have to learn a new API. It uses standard (DOM, ECMAScript) properties and methods throughout which also means that there is no need for a lot of accompanying documentation. [1] http://dean.edwards.name/ [2] http://code.google.com/p/base2/
nostrademons · 2008-02-09
It's very hard to reliably obfuscate JavaScript because the language is dynamic enough that you might refer to object fields or function names through dynamically-computed strings. Any attempt to obfuscate these runs up against the halting problem. So you have to rely on conservative approximations... Packer (http://dean.edwards.name/packer/) will rename all local variables to single characters, along with removing all whitespace and optionally base-62 encoding the text. It also has a compression scheme, but it's trivial to defeat this by replacing eval() with document.write(). I think that's the best you can do with any JavaScript-only compressor. I should probably mention that even JSMin'd text is a real pain to go through. Someone that's dedicated enough could do it (just like how people were reverse-engineering the Google Maps frontend), but nobody wants to read through a lot of code with no indentation. Also, you're much better off with one large JSMin'd file than a bunch of streamed sections. Aside from being simpler, it's more to look through. Otherwise, people can sniff the stream through Fiddler or Analyzer and take a look at when segments are loaded, which often gives them more information than they'd have otherwise. And re-indenting 500k is a lot more of a pain than re-indenting a 500-byte segment.
jtsagata · 2012-11-02
It is better do this with HTC or XBL. Look here http://dean.edwards.name/moz-behaviors/ Sadly only firefox and ie can do this for years
andfarm · 2011-05-13
Harmless Javascript minification can be difficult to distinguish from intentional obfuscation. Packer in base62 mode (http://dean.edwards.name/packer/) is a good example.
tiles · 2011-01-09
The last update of ie7.js was in March: http://dean.edwards.name/weblog/2010/03/ie7js-update/ Supports up to IE9.
amix · 2010-05-25
Another solution might be to set the sourcing of JavaScript in a timeout, e.g. setTimeout(_sourceJavascript, 300). I think this will bypass the blocking nature. This is only based on my intuition thought - it isn't tested. -- It's also important to note that window.onload will only fire when everything is loaded (including scripts and large images). To bypass this problem you should use something like jQuery.ready(document) or Dean Edwards onload hack ( http://dean.edwards.name/weblog/2005/09/busted/ ).
Macha · 2010-05-01
A much less, well, rude way to do it would be to throw Dean Edward's IE8.js or IE9.js scripts on it: http://dean.edwards.name/weblog/2010/03/ie7js-update/ and don't do anything else for compatibility, then put a little notice. They probably won't pay attention either way, but you won't be needlessly cutting people off either.
jeresig · 2010-04-26
Good question - I was inspired heavily by Dean Edwards' original Base Class library, it seemed to make the most sense when I was using it. The original code: http://dean.edwards.name/weblog/2006/03/base/ The current code: http://code.google.com/p/base2/source/browse/trunk/src/base2/Base.js
slashcom · 2007-11-12
I'd say there are really only two reasons that have stopped widespread adoption of PNG: 1. The file sizes can be rather large (less of a problem these days) 2. IE6 improperly displays PNG alpha (This is big one). Even the "IE7" javascript hack (http://dean.edwards.name/IE7/) didn't really catch on.
pajtai · 2014-06-02
I took the code presented and put it into packer - http://dean.edwards.name/packer/ , and the "nice" output was not very helpful in that it still looked obfuscated. Maybe I'm misunderstanding something. So the input to js nice was the packed generateSeries function: eval(function(p,a,c,k,e,r){e=function(c) {return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35? String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/, String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c-- )if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('4 3(e){2 t=[];2 n=f+e;2 r=6+e;k(i=1;i<=6;i++){2 s=5.y(5.a()*(r- n+1)+n);t.b([i,s]);n++;r++}c t}$(d).B(4(){2 e=3(0);2 t=3(g);$.h($("#j"),[{7:"l",8:e},{7:"o",8:t}],{p:{q:{u: ["#v","#w"]}},x:{9:z},A: {9:m}})})',38,38,'||var|generateSeries|function|Math|200|label |data|ticks|random|push|return|document||100|300|plot||flotcon tainer|for|data1|10||data2|grid|backgroundColor||||colors|D1D1 D1|7A7A7A|xaxis|floor|20|yaxis|ready'.split('|'),0,{}))
eyko · 2022-04-27
I don't remember the original Gmail having a rich editor in the compose view (I've been trying to source some screenshots but can't seem to find any with the compose view), but I do remember it being pretty impressive for the time. There definitely were a few libraries pushing the envelope back then. SproutCore for instance was around in 2006 and Apple built it's first version of MobileMe on it[1]. Prototype.js[2] first came out in 2005. I believe it was Prototype.js that first popularised the dollar sign $() for CSS selectors, or was it cssQuery[3]? Prototype also had Dojo[4] as healthy competition right from the start. I also remember YUI[5] and its offshot Ext.js[6]. Most will also remember YUI[4] and its offshoot Ext.js[5] 1. https://techcrunch.com/2008/06/09/want-to-try-out-mobileme-check-out-s… 2. https://en.wikipedia.org/wiki/Prototype_JavaScript_Framework 3. http://dean.edwards.name/my/cssQuery/ 4. https://en.wikipedia.org/wiki/Dojo_Toolkit 5. https://en.wikipedia.org/wiki/YUI_Library 6. https://en.wikipedia.org/wiki/Ext_JS

Keyboard shortcuts

/Search
j kNext / previous blog
EnterOpen selected blog
vVisit the blog site
fFollow / unfollow
lSwitch grid / list view
dSwitch dark mode
g hHome
g pTop posts
g tTopics
g fFollowing
g lLiked
g yHistory
g qFAQ
EscBack / close