Take the 2-minute tour ×

I have a project that is using both jQuery 1.3.2 and YUI 2.6, and it has come time to pick one or the other. I have a lot of developers that love jQuery and can't live without it, but I think some of the features of YUI 3 are a better fit for the project (e.g. the base widget).

I was trying to find a mapping of functionality between jQuery and YUI 3, and found jQuery - YUI3 Rosetta Stone, which compared jQuery 1.4.2 to YUI 3.0.0. I am looking at YUI 3.1.1 or the 3.2.0 preview, and wonder if there were other resources? For a brief moment, I was tempted to write a adapter/shim layer, but think that would just confuse the issue and it is better for developers to work in one paradigm or the other.

Update: I see the above content has been migrated to http://www.jsrosettastone.com/, and "The YUI team has graciously taken over the upkeep." It now compares jQuery 1.4.2 and YUI 3.1.2

share|improve this question
Is there a reason you cannot use both perhaps? I know, I know, 2 frameworks!! All hell breaks loose! But you could still use jQuery for low level and common functionality, and YUI for widgets. There are both designed to be pretty non-polluting, and jQuery-min is tiny enough –  Java Drinker Jul 28 '10 at 17:24
add comment

2 Answers

up vote 4 down vote accepted

Carlos's Rosetta Stone is the best resource I know of comparing the two libraries feature-for-feature. If you find inaccuracies given the evolution of YUI since 3.0.0, Carlos does have the resource up on GitHub and welcomes updates/contributions to it.

share|improve this answer
add comment

I'm slightly confused. If you don't want to rewrite your jquery code: include jquery. If you want to use only one library and that's yui: rewrite the legacy jquery code to yui.

But if you're moving from yui2 to yui3, you'll have to rewrite the yui code as well, they're different enough. I think the first thing you need to do to have think - if there are resources for a refactor, I'd avoid thinking in shims and extra layers.

The personal opinion though is yui3 is still not quite ready for primetime, despite all the cool and very elegant stuff they're doing.

share|improve this answer
add comment

Your Answer


