• Home
  • Quick Start
    • Configurator
    • Download YUI 3
  • Documentation
    • User Guides
    • Examples
    • Tutorials
    • API Docs
  • Community
    • Gallery
    • Blog
    • Forums
    • YUI Theater
    • Calendar
  • Contribute
    • YUI on GitHub »
    • File a Ticket
    • View Tickets
    • Dashboard
  • Other Projects
    • YUI 2
    • YUI Compressor
    • YUI Doc »
    • YUI Builder
    • YUI PHP Loader
    • YUI Test
    • YUI Website

Blog: Archive for May, 2007

|
Newer Entries »

London’s Hacking — and YUI’s Nate Koechley Will Be There

In case you haven’t heard yet, Yahoo!’s Hack Day is coming to Europe. I can hardly do more justice to this event than Tom Coates has done on his blog, but here are some important details:

  • Are you invited? Naturally.
  • Where is it? Alexandra Palace, London.
  • When is it? June 16 and 17, 2007.
  • How much does it cost? It’s free.
  • Will Beck be playing? Hey, it’s London — there will be great music in the vicinity, if not at the Hack Day.
  • How do I sign up? Hackday.org has a registration page.

YUI engineer Nate Koechley.I’m pleased to report that, as with Hack Day in Sunnyvale, YUI will be well represented. YUI engineer Nate Koechley, author of YUI’s Reset, Fonts, and Grids libraries, will be on the speakers roster along with Yahoo! UK’s Christian Heilmann.

In Sunnyvale, we saw some great hacks in which YUI helped provide the interface for a variety of Yahoo! web services, and we hope to see more of the same in London. With the intensely creative and committed web development community in the London area, I’m sure that this event will be a memorable one. Can the London event top a handbag that automatically documents your day in pictures and updates your photostream on Flickr? Time will tell. But those of us in Sunnyvale know that when we have our next Hack Day here in California we’ll have a whole new bar to clear in our hacking. And we can’t wait for that.

Happy hacking, and for those of you in YUI user community in London please track Nate and Christian down and say hello.

By Eric MiragliaMay 14th, 2007

YUI Theater — David Weinberger in Conversation with Bradley Horowitz

This is a little bit off our usual beat here on YUIBlog, but when David Weinberger (author of Small Pieces Loosely Joined and one of the most consistently engaging voices in the technosphere) stops by Yahoo! to talk about the world, its people, and their relationship to information…well, that seems like something worth sharing. David dropped in to have a wide-ranging conversation with Yahoo’s Bradley Horowitz with topics spinning out from David’s new book, Everything Is Miscellaneous.

Among many important insights, here’s the essense of David’s thesis in the new book: Categories are now applied to content when it is extracted from the infospace, whereas historically curators of information (such as librarians) have invested immense energy in organizing information on its way in. Here are a few additional nuggets to look forward to in the dialogue:

  • David argues that we are moving into a post-Aristotilean posture with respect to how information is organized, overthrowing a regime of philosophy that held for two millennia.
  • Everything has to have a place in a physical library. Given that so many of our ideas ore written on on paper, we have regimes of power. People who control the information have the power.
  • But “the book [Everything Is Miscellaneous] is an argument against the sense that there’s a right way to organize the world.”
  • “The instinct that built the internet is, ‘You want to post it, post it.’ We’ll figure out later how to find it. We’ll invent as many techniques as we possibly can to help you find it.”

Video of the conversation is available in an embeddable and platform-agnostic Flash format (embedded below) and as an iPod-compatible download. (If your computer doesn’t recognize the .m4v file, try renaming it to .mp4.

Havi Hoffman shot still photos at the event; you can find her images on Flickr.

In Case You Missed…

Some other recent videos from the YUI Theater series:

  1. John Resig: "Advancing JavaScript with Libraries" (Yahoo! Video | .m4v download)
  2. Doug Geoffray: "From the Mouth of a ScreenReader" (Yahoo! Video | .m4v download)
  3. Gopal Venkatesan: "Efficient JavaScript" (Yahoo! Video
  4. Joe Hewitt: "Welcome to Firebug 1.0 " (Yahoo! Video | .m4v download)

Much more content, including Douglas Crockford’s well-received series of lectures on JavaScript, is available on the YUI Theater website.

By Eric MiragliaMay 12th, 2007

Adrien Cahen’s YUI Fonts Dashboard Widget

One core advantage of the YUI Fonts foundation (Reset, Fonts, Grids) created by YUI engineer Nate Koechley is that it allows you to define fonts in relative terms. That means (even in IE) that fonts zoom or shrink in size as the user increases/decreases the zoom level of the page. This is really good news for people who come to your site — whether they’re zooming because their monitor’s screen resolution is ultra-high or because they’ve misplaced their bifocals, the ability to zoom the size of text is a key feature of accessibility for all sighted users. (And what we love about YUI Grids is that it allows you to do that zooming on the page’s basic wireframe as well…but that’s another story.)

To get this nice zoomability, the Fonts CSS package requires you to specify fonts in relative percentages rather than pixel sizes; we provide a handy lookup table in the documentation to show you which percentage value to use for which "base" pixel size you’re targeting (eg, the pixel size you want to use when the zoom level is set to normal).

Yahoo Messenger engineer Adrien Cahen wanted that information to be even more handy, so he whipped up a Dashboard widget that lays out the YUI Fonts sizing table for you.

Adrien Cahen's YUI Fonts Dashboard Widget

If you’re a Mac user, now you can have your YUI Fonts sizing chart at the touch of your F12 key. Sweet. Thanks, Adrien.

By Eric MiragliaMay 11th, 2007

I Object

One of the two really clever ideas in JavaScript is that objects are dynamic collections with differential inheritance. Differential inheritance means that when object B inherits from object A, object B does not have to contain a copy of all of object A’s stuff. Object B only needs to contain the differences. This saves time and memory, and it allows the augmenting of an object system after the objects have been instantiated. That can be really useful in Ajax applications which have to deal with variable network latency.

Unfortunately, JavaScript got the details wrong. As we saw in for in Intrigue, the for statement can interact badly with methods supplied by the prototype. A little bit of care is required to make for statements work correctly.

Similar care is also required when using objects as general collections. Since methods act like any other member, you can sometimes get false positives from inherited methods.

For example, let’s say we have an application which will look at the words in a text, and that we will take some sort of action if a word matches a word on our list. Using the string split method, we can easily transform a text into an array of words. And we can use an object to make our list of special words.

var myList = {
hope: true,
springs: true,
eternal: true
};

We then loop over the array of words, and on each iteration we will match a word against the list.

if (myList[arrayOfWords[i]]) {
// A match!
}

So we won’t match "construct". But we will match "hope". Great. Our code works. Or does it? This code will also match "constructor" even though "constructor" is not in our list. Why is this? It is because every object has "construct" member. So we get a false positive. Any member anywhere in the prototype chain can cause a false positive.

So how can we fix this? JavaScript’s in operator is useless because it produces the same false positive. We could take advantage of the fact that all of the values in myList are true by doing exact comparisons.

if (myList[arrayOfWords[i]] === true) {
// A match!
}

That works. But suppose we want myList‘s values to be functions which will be called when a key matches. In that case, we can’t look for a known value, and

if (typeof myList[arrayOfWords[i]] === 'function') {
// A match!
}

won’t work because myList.constructor is also a function. What we can do is explicitly reject keys that come from the prototype chain.

var word = arrayOfWords[i];
if (myList.hasOwnProperty(word) && myList[word]) {
// A match!
}

So the solution here is the same solution required to make for statements work correctly: the hasOwnProperty method. If we use it to guard against unintended inheritance, then we can safely use JavaScript’s objects as general containers. We can make JavaScript work correctly at the cost of a bit of ugliness in our code.

It is a nuisance, it is irritating, and it feels like a waste of time. You could also say the same thing about washing your hands after using the restroom. Do it anyway. Good hygiene is good for you. And your code.

By Douglas CrockfordMay 10th, 2007

Job Announcement: The YUI Team Is Hiring an Engineer To Work on Firebug

It’s no secret that we’re fans of Firebug, the diabolically useful Firefox extension from Joe Hewitt that provides integrated debugging features, DOM inspection, live HTML/CSS/JavaScript manipulation, profiling, and more. Today we’re pleased to announce that we’re putting our money where our mouth is by contributing back to the Firebug project.

Toward that end, we’re opening a search for a full-time developer to work with Joe on advancing the Firebug roadmap. This developer will be a member of the YUI team and a full-time Yahoo! employee. The job description follows. If you’re interested in applying for this position, please send your résumé, including links to relevant projects/portfolio items, to yui-jobs /at/ yahoo /dash/ inc /dot/ com. (Principals only; no recruiters, please.)

To learn more about Firebug, visit the website and the project page on Google Code. You may also want to watch this video of Joe introducing the feature set of Firebug 1.0 (129 MB .mp4; also available on Yahoo! Video in Flash). To learn more about the Yahoo! User Interface Library (YUI), visit our website, download YUI, and check in on the YUI Forums.

YUI/Firebug Engineer: Job Description

  • Position: Technical Yahoo!/Senior Front-End Engineer
  • Location: Sunnyvale, CA

The Yahoo! User Interface (YUI) team is looking for an engineer to work on the open-source Firebug extension for Firefox (http://getfirebug.com). This developer will work closely with Firebug’s creator, Joe Hewitt, as well as with senior engineers on the YUI team to continue Firebug’s evolution as the premier open-source debugging and analysis tool. Firebug is largely written in JavaScript and CSS, so a strong background in frontend engineering is required. Moreover, experience designing and creating APIs enabling modular extensibility will be a requirement in the next phase of Firebug’s development. Because Firebug is closely tied to Mozilla software, the ability to work productively with the Mozilla community (both as a developer and API consumer) is important.

Minimum Job Qualifications:

  • You must have a strong command of X/HTML, DOM, CSS, JavaScript, cross-browser compatibility issues, and client-side performance optimization.
  • You must have a strong command of client/server programming in HTTP environments, including a strong working knowledge of the HTTP protocol.
  • You must have a successful track record of creating and documenting APIs that enable modular, performant extensibility.
  • You must have superior writing and public-speaking skills.
  • You must have a strong attention to detail.
  • Computer Science degree or equivalent work experience required.

Preferable Job Qualifications:

  • You should have 5+ years of frontend engineering experience building web-enabled functionality beyond the traditional web-page — e.g., XUL applications, browser extensions, Greasemonkey widgets, etc.
  • Experience contributing to Mozilla or other open-source projects is highly desired.
  • Experience with C/C++ is highly desired.
  • Familiarity with YUI, Dojo, JQuery and other JavaScript/CSS libraries is a plus.
  • Experience with Javascript/XML-based widget engines is a plus.

If you’re interested, please provide URLs and code samples of your work for review to yui-jobs /at/ yahoo /dash/ inc /dot/ com. (Principals only; no recruiters, please.)

Yahoo! Inc. is an equal opportunity employer. For more information or to search all of our openings worldwide, please visit http://careers.yahoo.com.

By Eric MiragliaMay 7th, 2007
|
Newer Entries »

Pages

  • About
  • Contribute
  • YUI Jobs

Recent Posts

  • YUI Weekly for May 17th, 2013
  • Yahoo’s International Team Is Hiring!
  • YUICompressor 2.4.8 Released
  • YUI 3.10.1 Released to Fix SWF Vulnerability
  • YUI Weekly for May 10th, 2013

Archives

Categories

  • Accessibility (25)
  • CSS 101 (6)
  • Design (51)
  • Development (590)
  • Frontend Jobs at Yahoo (13)
  • Graded Browser Support (8)
  • In the Wild (63)
  • Miscellany (11)
  • Open Hours (44)
  • Performance (23)
  • Releases (25)
  • Target Environments (11)
  • Yeti (3)
  • YUI 3 Gallery (29)
  • YUI Events (45)
  • YUI Implementations (55)
  • YUI Theater (146)
  • YUI Weekly (37)

Meta

  • Log in
  • Entries RSS
  • Comments RSS
  • WordPress.org
© 2013 YUI Blog