views:

221

answers:

2

Okay, so I'm not a Java guy, but I work with loads of them. We generally load Prototype with Tapestry 5, as Tapestry was built on this javascript library.

As a UI/front end developer/engineer, I know the awesomeness of jQuery and the lack of prototype therein. (Feel free to debate that elsewhere -- this ticket doesn't concern that question, ha.)

I've been curious for some time if it's possible to port jQuery into Tapestry instead of Prototype -- as in completely removing Prototype and Scriptaculous -- I realize it kind of defeats the purpose of the already bundled Prototype, but I wanted other opinions on the matter.

Thanks.

UPDATE:

We had the inventor of Tapestry visit us @ work and he discussed the explicit need for an agnostic disconnect of type of library in future versions of Tapestry. This means, hypothetically, one could bundle jQuery or Prototype with Tapestry, or possibly some other library.

For the win!

+2  A: 

Yes, quite.

There is an open issue in integrate this into the core: https://issues.apache.org/jira/browse/TAP5-486.

The problem is to adhere to the back compatibility pieces of T5. You would not need to worry about that for your single project.

To do so, one of your Java peoples will need to create an IoC Service which grabs the Prototype rendering and replaces it with jQuery. I do not have the code in front of me, so some research will need to be had by all.

Short answer, yes, it is possible just needs some time investment.

Dustin Digmann
+1  A: 

There's a tapestry-jquery project on github.

I haven't tried it yet but it looks promising and is supposed to do exactly what you're asking for.

Martin
I'll definitely look into this. Thx!
American Yak