Re: Struts 2 Components

2012-01-31 Thread Jeromy Evans
Hi Christian,

We also started looking at creating custom for YUI while it was still in its 
heyday (https://cwiki.apache.org/S2PLUGINS/yui-plugin.html).

I encountered several significant problems creating struts2 tags that attempt 
to abstract the details of client-side frameworks away:
  - you end up with sub-optional tags that can't exploit all the API of the 
client-side framework
  - the struts-dev developers end up supporting queries about JQuery, Dojo, YUI 
etc, that are best supposed within those respective communities
  - you end up with javascript namespace mess, inline javascript mess, 
complications regarding JS dependencies (in contrast to current best practices 
of the respective frameworks)

Personally I'm more inclined to head in the opposite direction; drop struts 2 
tags completely, leave it to the Results to provide ways to bind data from/for 
the context; focus on Struts2's hot-pluggable action-based (request-focused) 
framework with it's uniquely excellent InterceptorStack, ValueStack and Result 
architecture. 

eg. For related issues, see LinkedIn Engineering blog entry: Leaving JSPs in 
the dust: moving LinkedIn to dust.js client-side templates
https://engineering.linkedin.com/frontend/leaving-jsps-dust-moving-linkedin-dustjs-client-side-templates

Regards,
 Jeromy Evans

On 28/01/2012, at 10:28 PM, Christian Grobmeier wrote:

 Great examples. I will look into it.
 
 May I ask you why you didn't develop this at the struts repos? With
 dojo tags going away struts2-jQuery is a very strong replacement.
 Would be cool to see this somewhere more prominent on the struts page.
 I must say, I have either missed it or left it out because I always
 start first with on board tools
 
 On Sat, Jan 28, 2012 at 1:20 AM, Johannes Geppert jo...@apache.org wrote:
 That's exactly what I try to do with the Struts2 jQuery Plugin.
 
 http://code.google.com/p/struts2-jquery/
 http://code.google.com/p/struts2-jquery/
 
 Take a look at the Showcases to see which Components are already supported.
 
 http://www.weinfreund.de/struts2-jquery-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-grid-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-grid-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-mobile-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-mobile-showcase/index.action
 
 -
 web: http://www.jgeppert.com
 twitter: http://twitter.com/jogep
 --
 View this message in context: 
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5437096.html
 Sent from the Struts - Dev mailing list archive at Nabble.com.
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org
 
 
 
 
 -- 
 http://www.grobmeier.de
 https://www.timeandbill.de
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org
 


-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-30 Thread Johannes Geppert
This has several reasons. First I start this project as a non Struts
Committer 
and second this plugin produce high support and user mailing list traffic.
Some devlopers was in fear to have the same trouble like with the dojo
plugin.

Johannes


Christian Grobmeier wrote
 
 May I ask you why you didn't develop this at the struts repos? With
 dojo tags going away struts2-jQuery is a very strong replacement.
 Would be cool to see this somewhere more prominent on the struts page.
 I must say, I have either missed it or left it out because I always
 start first with on board tools
 


-
web: http://www.jgeppert.com
twitter: http://twitter.com/jogep
--
View this message in context: 
http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5442119.html
Sent from the Struts - Dev mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-28 Thread Christian Grobmeier
Great examples. I will look into it.

May I ask you why you didn't develop this at the struts repos? With
dojo tags going away struts2-jQuery is a very strong replacement.
Would be cool to see this somewhere more prominent on the struts page.
I must say, I have either missed it or left it out because I always
start first with on board tools

On Sat, Jan 28, 2012 at 1:20 AM, Johannes Geppert jo...@apache.org wrote:
 That's exactly what I try to do with the Struts2 jQuery Plugin.

 http://code.google.com/p/struts2-jquery/
 http://code.google.com/p/struts2-jquery/

 Take a look at the Showcases to see which Components are already supported.

 http://www.weinfreund.de/struts2-jquery-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-grid-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-grid-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-mobile-showcase/index.action
 http://www.weinfreund.de/struts2-jquery-mobile-showcase/index.action

 -
 web: http://www.jgeppert.com
 twitter: http://twitter.com/jogep
 --
 View this message in context: 
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5437096.html
 Sent from the Struts - Dev mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org




-- 
http://www.grobmeier.de
https://www.timeandbill.de

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-28 Thread Łukasz Lenart
2012/1/28 Christian Grobmeier grobme...@gmail.com:
 May I ask you why you didn't develop this at the struts repos? With
 dojo tags going away struts2-jQuery is a very strong replacement.
 Would be cool to see this somewhere more prominent on the struts page.
 I must say, I have either missed it or left it out because I always
 start first with on board tools

The decision was made same time ago to develop the jquery-plugin
separately, thus allowed to speed up the development process as it
isn't related to Struts 2 Core itself (which sometimes slow down ;-)
IMHO it was a good idea as Johannes with community can control when a
new version should be released and it isn't tied to S2 Core.

But you're right, we should promote the jquery-plugin better, I don't
know if we can do this on the S2 main page.


Regards
-- 
Łukasz

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-27 Thread Johannes Geppert
I agree to Martin, there are enough Component Frameworks available.
That's one point I personally like on Struts2, that all view Logic is in
my JSP/Fremarker/Velocity Template. I know Wicket Apps which have really
nice 
and clear looking HTML Files, but the Java Files are bloated and looks dirty
hacked.

Maybe there is a Struts2 way to add this Feature as an Plugin for this
developers how like it.

Johannes

-
web: http://www.jgeppert.com
twitter: http://twitter.com/jogep
--
View this message in context: 
http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5436126.html
Sent from the Struts - Dev mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-27 Thread Christian Grobmeier
Hello folks,

thanks for all your insights and sharing the old stories. It was not
my intention to make S2 to some kind of Wicket-Clone. Now, after I
have thought a bit more about what I wanted to gain, I think the
components I speak of are more or less components like we already
have with S2 tags. Probably there is a cool way to provide some frame
for creating tags themselves easily. Another possible idea I had was,
what if there were a JS based way to capsule frontend logic. Or even
more experimental in Dart. probably a tag like:

s2:component id=something

can create a div id=something/ and executes a JS script like this:

var Component = function(id) {
}
Component.prototype.execute = function(){
}
Component.prototype.on = function(event){
}

These JS components can use AJAX to call plain Struts Actions.

Looking at Mustache.js, Require.js, jQuery and so on there might be a
good chance to create a modern frontend technology to work with plain
Struts 2 actions.

What Jo wrote below is exactly my feeling on Wicket components. That
is one of the reasons i have chosen Struts and not Wicket for my app.
Now I deal with the fact that I need to organize my JS, which becomes
huge. A generic or recommended Struts approach would help me.

I call it the playground pattern: you get a first playground back
from struts - usual jsp stuff. Then you have some Struts js which let
you create frontend components using struts services (or even Dart, my
preferred language atm).

Of course the action framework needs no change then and such a js
frontend would be doable as s2 plugin.

Not sure if people now say: hey, go ahead and use GWT if you would
like to do things like that ;-) Anyway, I think giving Struts users
something how they can easily make up own tags or such a JS beast
might be cool.

Still sounds bad?

Cheers
Christian

On Fri, Jan 27, 2012 at 6:50 PM, Johannes Geppert jo...@apache.org wrote:
 I agree to Martin, there are enough Component Frameworks available.
 That's one point I personally like on Struts2, that all view Logic is in
 my JSP/Fremarker/Velocity Template. I know Wicket Apps which have really
 nice
 and clear looking HTML Files, but the Java Files are bloated and looks dirty
 hacked.

 Maybe there is a Struts2 way to add this Feature as an Plugin for this
 developers how like it.

 Johannes

 -
 web: http://www.jgeppert.com
 twitter: http://twitter.com/jogep
 --
 View this message in context: 
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5436126.html
 Sent from the Struts - Dev mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org




-- 
http://www.grobmeier.de
https://www.timeandbill.de

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-27 Thread Dave Newton
That's what the jQuery tags do.

Dave

On Fri, Jan 27, 2012 at 1:06 PM, Christian Grobmeier grobme...@gmail.comwrote:

 Hello folks,

 thanks for all your insights and sharing the old stories. It was not
 my intention to make S2 to some kind of Wicket-Clone. Now, after I
 have thought a bit more about what I wanted to gain, I think the
 components I speak of are more or less components like we already
 have with S2 tags. Probably there is a cool way to provide some frame
 for creating tags themselves easily. Another possible idea I had was,
 what if there were a JS based way to capsule frontend logic. Or even
 more experimental in Dart. probably a tag like:

 s2:component id=something

 can create a div id=something/ and executes a JS script like this:

 var Component = function(id) {
 }
 Component.prototype.execute = function(){
 }
 Component.prototype.on = function(event){
 }

 These JS components can use AJAX to call plain Struts Actions.

 Looking at Mustache.js, Require.js, jQuery and so on there might be a
 good chance to create a modern frontend technology to work with plain
 Struts 2 actions.

 What Jo wrote below is exactly my feeling on Wicket components. That
 is one of the reasons i have chosen Struts and not Wicket for my app.
 Now I deal with the fact that I need to organize my JS, which becomes
 huge. A generic or recommended Struts approach would help me.

 I call it the playground pattern: you get a first playground back
 from struts - usual jsp stuff. Then you have some Struts js which let
 you create frontend components using struts services (or even Dart, my
 preferred language atm).

 Of course the action framework needs no change then and such a js
 frontend would be doable as s2 plugin.

 Not sure if people now say: hey, go ahead and use GWT if you would
 like to do things like that ;-) Anyway, I think giving Struts users
 something how they can easily make up own tags or such a JS beast
 might be cool.

 Still sounds bad?

 Cheers
 Christian

 On Fri, Jan 27, 2012 at 6:50 PM, Johannes Geppert jo...@apache.org
 wrote:
  I agree to Martin, there are enough Component Frameworks available.
  That's one point I personally like on Struts2, that all view Logic is in
  my JSP/Fremarker/Velocity Template. I know Wicket Apps which have really
  nice
  and clear looking HTML Files, but the Java Files are bloated and looks
 dirty
  hacked.
 
  Maybe there is a Struts2 way to add this Feature as an Plugin for this
  developers how like it.
 
  Johannes
 
  -
  web: http://www.jgeppert.com
  twitter: http://twitter.com/jogep
  --
  View this message in context:
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5436126.html
  Sent from the Struts - Dev mailing list archive at Nabble.com.
 
  -
  To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
  For additional commands, e-mail: dev-h...@struts.apache.org
 



 --
 http://www.grobmeier.de
 https://www.timeandbill.de

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org




Re: Struts 2 Components

2012-01-27 Thread Christian Grobmeier
you mean the tags listed here?
http://struts.apache.org/2.3.1.2/docs/tag-reference.html

The are listing this btw too:
http://struts.apache.org/2.3.1.2/docs/dojo-div.html
which is pointing to the dojo plugin somehow

On Fri, Jan 27, 2012 at 7:09 PM, Dave Newton davelnew...@gmail.com wrote:
 That's what the jQuery tags do.

 Dave

 On Fri, Jan 27, 2012 at 1:06 PM, Christian Grobmeier 
 grobme...@gmail.comwrote:

 Hello folks,

 thanks for all your insights and sharing the old stories. It was not
 my intention to make S2 to some kind of Wicket-Clone. Now, after I
 have thought a bit more about what I wanted to gain, I think the
 components I speak of are more or less components like we already
 have with S2 tags. Probably there is a cool way to provide some frame
 for creating tags themselves easily. Another possible idea I had was,
 what if there were a JS based way to capsule frontend logic. Or even
 more experimental in Dart. probably a tag like:

 s2:component id=something

 can create a div id=something/ and executes a JS script like this:

 var Component = function(id) {
 }
 Component.prototype.execute = function(){
 }
 Component.prototype.on = function(event){
 }

 These JS components can use AJAX to call plain Struts Actions.

 Looking at Mustache.js, Require.js, jQuery and so on there might be a
 good chance to create a modern frontend technology to work with plain
 Struts 2 actions.

 What Jo wrote below is exactly my feeling on Wicket components. That
 is one of the reasons i have chosen Struts and not Wicket for my app.
 Now I deal with the fact that I need to organize my JS, which becomes
 huge. A generic or recommended Struts approach would help me.

 I call it the playground pattern: you get a first playground back
 from struts - usual jsp stuff. Then you have some Struts js which let
 you create frontend components using struts services (or even Dart, my
 preferred language atm).

 Of course the action framework needs no change then and such a js
 frontend would be doable as s2 plugin.

 Not sure if people now say: hey, go ahead and use GWT if you would
 like to do things like that ;-) Anyway, I think giving Struts users
 something how they can easily make up own tags or such a JS beast
 might be cool.

 Still sounds bad?

 Cheers
 Christian

 On Fri, Jan 27, 2012 at 6:50 PM, Johannes Geppert jo...@apache.org
 wrote:
  I agree to Martin, there are enough Component Frameworks available.
  That's one point I personally like on Struts2, that all view Logic is in
  my JSP/Fremarker/Velocity Template. I know Wicket Apps which have really
  nice
  and clear looking HTML Files, but the Java Files are bloated and looks
 dirty
  hacked.
 
  Maybe there is a Struts2 way to add this Feature as an Plugin for this
  developers how like it.
 
  Johannes
 
  -
  web: http://www.jgeppert.com
  twitter: http://twitter.com/jogep
  --
  View this message in context:
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5436126.html
  Sent from the Struts - Dev mailing list archive at Nabble.com.
 
  -
  To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
  For additional commands, e-mail: dev-h...@struts.apache.org
 



 --
 http://www.grobmeier.de
 https://www.timeandbill.de

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org





-- 
http://www.grobmeier.de
https://www.timeandbill.de

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-27 Thread Dave Newton
Those are Dojo tags, not jquery tags. Same difference--they make Ajax calls
to Struts actions. Isn't that what you said you wanted?

On Fri, Jan 27, 2012 at 1:15 PM, Christian Grobmeier grobme...@gmail.comwrote:

 you mean the tags listed here?
 http://struts.apache.org/2.3.1.2/docs/tag-reference.html

 The are listing this btw too:
 http://struts.apache.org/2.3.1.2/docs/dojo-div.html
 which is pointing to the dojo plugin somehow

 On Fri, Jan 27, 2012 at 7:09 PM, Dave Newton davelnew...@gmail.com
 wrote:
  That's what the jQuery tags do.
 
  Dave
 
  On Fri, Jan 27, 2012 at 1:06 PM, Christian Grobmeier 
 grobme...@gmail.comwrote:
 
  Hello folks,
 
  thanks for all your insights and sharing the old stories. It was not
  my intention to make S2 to some kind of Wicket-Clone. Now, after I
  have thought a bit more about what I wanted to gain, I think the
  components I speak of are more or less components like we already
  have with S2 tags. Probably there is a cool way to provide some frame
  for creating tags themselves easily. Another possible idea I had was,
  what if there were a JS based way to capsule frontend logic. Or even
  more experimental in Dart. probably a tag like:
 
  s2:component id=something
 
  can create a div id=something/ and executes a JS script like this:
 
  var Component = function(id) {
  }
  Component.prototype.execute = function(){
  }
  Component.prototype.on = function(event){
  }
 
  These JS components can use AJAX to call plain Struts Actions.
 
  Looking at Mustache.js, Require.js, jQuery and so on there might be a
  good chance to create a modern frontend technology to work with plain
  Struts 2 actions.
 
  What Jo wrote below is exactly my feeling on Wicket components. That
  is one of the reasons i have chosen Struts and not Wicket for my app.
  Now I deal with the fact that I need to organize my JS, which becomes
  huge. A generic or recommended Struts approach would help me.
 
  I call it the playground pattern: you get a first playground back
  from struts - usual jsp stuff. Then you have some Struts js which let
  you create frontend components using struts services (or even Dart, my
  preferred language atm).
 
  Of course the action framework needs no change then and such a js
  frontend would be doable as s2 plugin.
 
  Not sure if people now say: hey, go ahead and use GWT if you would
  like to do things like that ;-) Anyway, I think giving Struts users
  something how they can easily make up own tags or such a JS beast
  might be cool.
 
  Still sounds bad?
 
  Cheers
  Christian
 
  On Fri, Jan 27, 2012 at 6:50 PM, Johannes Geppert jo...@apache.org
  wrote:
   I agree to Martin, there are enough Component Frameworks available.
   That's one point I personally like on Struts2, that all view Logic is
 in
   my JSP/Fremarker/Velocity Template. I know Wicket Apps which have
 really
   nice
   and clear looking HTML Files, but the Java Files are bloated and looks
  dirty
   hacked.
  
   Maybe there is a Struts2 way to add this Feature as an Plugin for this
   developers how like it.
  
   Johannes
  
   -
   web: http://www.jgeppert.com
   twitter: http://twitter.com/jogep
   --
   View this message in context:
 
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5436126.html
   Sent from the Struts - Dev mailing list archive at Nabble.com.
  
   -
   To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
   For additional commands, e-mail: dev-h...@struts.apache.org
  
 
 
 
  --
  http://www.grobmeier.de
  https://www.timeandbill.de
 
  -
  To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
  For additional commands, e-mail: dev-h...@struts.apache.org
 
 



 --
 http://www.grobmeier.de
 https://www.timeandbill.de

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org




Re: Struts 2 Components

2012-01-27 Thread Christian Grobmeier
On Fri, Jan 27, 2012 at 7:17 PM, Dave Newton davelnew...@gmail.com wrote:
 Those are Dojo tags, not jquery tags. Same difference--they make Ajax calls
 to Struts actions. Isn't that what you said you wanted?

well, in a way, yes. This would be the start of it. I thought more on
complete forms, build as a js component. It would not only send the
result, but would do some validation, update a dropdownbox when
selecting from another one such. More highlevel component support

Probably I should look into the jQuery tags. Still I was not able to
find them (or is it the project of Jo you are referring to?)

Maybe my ideas can be easily covered with this:
http://www.vitarara.org/cms/struts_2_cookbook/creating_a_ui_component

I will think about it.


 On Fri, Jan 27, 2012 at 1:15 PM, Christian Grobmeier 
 grobme...@gmail.comwrote:

 you mean the tags listed here?
 http://struts.apache.org/2.3.1.2/docs/tag-reference.html

 The are listing this btw too:
 http://struts.apache.org/2.3.1.2/docs/dojo-div.html
 which is pointing to the dojo plugin somehow

 On Fri, Jan 27, 2012 at 7:09 PM, Dave Newton davelnew...@gmail.com
 wrote:
  That's what the jQuery tags do.
 
  Dave
 
  On Fri, Jan 27, 2012 at 1:06 PM, Christian Grobmeier 
 grobme...@gmail.comwrote:
 
  Hello folks,
 
  thanks for all your insights and sharing the old stories. It was not
  my intention to make S2 to some kind of Wicket-Clone. Now, after I
  have thought a bit more about what I wanted to gain, I think the
  components I speak of are more or less components like we already
  have with S2 tags. Probably there is a cool way to provide some frame
  for creating tags themselves easily. Another possible idea I had was,
  what if there were a JS based way to capsule frontend logic. Or even
  more experimental in Dart. probably a tag like:
 
  s2:component id=something
 
  can create a div id=something/ and executes a JS script like this:
 
  var Component = function(id) {
  }
  Component.prototype.execute = function(){
  }
  Component.prototype.on = function(event){
  }
 
  These JS components can use AJAX to call plain Struts Actions.
 
  Looking at Mustache.js, Require.js, jQuery and so on there might be a
  good chance to create a modern frontend technology to work with plain
  Struts 2 actions.
 
  What Jo wrote below is exactly my feeling on Wicket components. That
  is one of the reasons i have chosen Struts and not Wicket for my app.
  Now I deal with the fact that I need to organize my JS, which becomes
  huge. A generic or recommended Struts approach would help me.
 
  I call it the playground pattern: you get a first playground back
  from struts - usual jsp stuff. Then you have some Struts js which let
  you create frontend components using struts services (or even Dart, my
  preferred language atm).
 
  Of course the action framework needs no change then and such a js
  frontend would be doable as s2 plugin.
 
  Not sure if people now say: hey, go ahead and use GWT if you would
  like to do things like that ;-) Anyway, I think giving Struts users
  something how they can easily make up own tags or such a JS beast
  might be cool.
 
  Still sounds bad?
 
  Cheers
  Christian
 
  On Fri, Jan 27, 2012 at 6:50 PM, Johannes Geppert jo...@apache.org
  wrote:
   I agree to Martin, there are enough Component Frameworks available.
   That's one point I personally like on Struts2, that all view Logic is
 in
   my JSP/Fremarker/Velocity Template. I know Wicket Apps which have
 really
   nice
   and clear looking HTML Files, but the Java Files are bloated and looks
  dirty
   hacked.
  
   Maybe there is a Struts2 way to add this Feature as an Plugin for this
   developers how like it.
  
   Johannes
  
   -
   web: http://www.jgeppert.com
   twitter: http://twitter.com/jogep
   --
   View this message in context:
 
 http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5436126.html
   Sent from the Struts - Dev mailing list archive at Nabble.com.
  
   -
   To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
   For additional commands, e-mail: dev-h...@struts.apache.org
  
 
 
 
  --
  http://www.grobmeier.de
  https://www.timeandbill.de
 
  -
  To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
  For additional commands, e-mail: dev-h...@struts.apache.org
 
 



 --
 http://www.grobmeier.de
 https://www.timeandbill.de

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org





-- 
http://www.grobmeier.de
https://www.timeandbill.de

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-27 Thread Johannes Geppert
That's exactly what I try to do with the Struts2 jQuery Plugin.

http://code.google.com/p/struts2-jquery/
http://code.google.com/p/struts2-jquery/ 

Take a look at the Showcases to see which Components are already supported. 

http://www.weinfreund.de/struts2-jquery-showcase/index.action
http://www.weinfreund.de/struts2-jquery-showcase/index.action 
http://www.weinfreund.de/struts2-jquery-grid-showcase/index.action
http://www.weinfreund.de/struts2-jquery-grid-showcase/index.action 
http://www.weinfreund.de/struts2-jquery-mobile-showcase/index.action
http://www.weinfreund.de/struts2-jquery-mobile-showcase/index.action 

-
web: http://www.jgeppert.com
twitter: http://twitter.com/jogep
--
View this message in context: 
http://struts.1045723.n5.nabble.com/Struts-2-Components-tp5432642p5437096.html
Sent from the Struts - Dev mailing list archive at Nabble.com.

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Struts 2 Components

2012-01-26 Thread Christian Grobmeier
Last mail for today :-)

Today there is a discussion on going, Tapestry vs Struts (on
tapestry-users list). Of course people are convinced of Tapestry, and
actually it is a great framework with huge benefits. And it is pretty
modern. People now say (and not only there) Struts is a dinosaur.

Well, what I really liked on Wicket was the idea on components. I
think Wicket failed with it. But Tapestry did something similar, and
there it is working. Then there is Vaading, another great framework
supporting components.

I look at Struts. I see, we can use different presentation layers here
too. I am just not sure what other than jsp is really working. Are we
sure JavaTemplates work? We support Sitemesh2, which is pretty
outdated too.

These days people go to Components. I have thought a while about it...
shouldn't it be possible to use components in STruts too? We have DI
in place, which is a good backbone for that.

For example, look at this:

class MyAction {
  @Inject
  MyComponent blub; // Implements StrutsComponent
}

body
  s2:component id=blub /
/body

Components might be able to return html. They can calculate. They can
be used with JSP. Looking at this:
http://tapestry.apache.org/component-reference.html

We can learn a bit from Tapestry here. Probably we are able to reuse
some of the components from them.

I begin to think a good frontend layer would bring benefits. Otherwise
it might happen S2 is more and more going into the direction service
layer, and for that it might not fit very well.

What do you think?

Cheers
Christian

--
http://www.grobmeier.de
https://www.timeandbill.de


-- 
http://www.grobmeier.de
https://www.timeandbill.de

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-26 Thread Martin Cooper
On Thu, Jan 26, 2012 at 3:34 AM, Christian Grobmeier
grobme...@gmail.com wrote:
 Last mail for today :-)

 Today there is a discussion on going, Tapestry vs Struts (on
 tapestry-users list). Of course people are convinced of Tapestry, and
 actually it is a great framework with huge benefits. And it is pretty
 modern. People now say (and not only there) Struts is a dinosaur.

 Well, what I really liked on Wicket was the idea on components. I
 think Wicket failed with it. But Tapestry did something similar, and
 there it is working. Then there is Vaading, another great framework
 supporting components.

 I look at Struts. I see, we can use different presentation layers here
 too. I am just not sure what other than jsp is really working. Are we
 sure JavaTemplates work? We support Sitemesh2, which is pretty
 outdated too.

 These days people go to Components. I have thought a while about it...
 shouldn't it be possible to use components in STruts too?

The classical distinction between styles of web frameworks is
action-oriented versus component-oriented. The two take different
approaches to the problem of building web apps, and each has its
place, depending on the goals and constraints of the app. Some people
pick one and try to use it for everything; others will pick the
appropriate tool for each job.

Since its very beginnings, Struts has been an action-oriented
framework. Over time, people have attempted to morph it into something
more component-oriented, or tried to build a component layer on top of
it. To me, that's a bit like trying to improve upon a screwdriver by
turning it into a hammer.

If you look back at the early history of JSF, you'll find the
beginnings of Apache Shale, which started out as a Struts subproject
to explore some component-oriented ideas in a Struts world. Shale was
split off from Struts because of the divergent perspectives of
action-oriented versus component-oriented developers. The project was
retired about 2 years ago, in part because many of the good ideas from
Shale were being adopted into JSF, and in part because of the
realisation that trying to morph an action-oriented framework into a
component-oriented one was an unnatural act. It made (and makes) more
sense, if you wanted a component-oriented framework, to focus on just
that, rather than bending another tool to needs for which it wasn't
designed.

Now, of course, that's not to say that there aren't ideas that might
be interesting for some people to explore, as a kind of Shale2 on top
of Struts2 (conceptually speaking). I'd just encourage you to think
carefully about why you would want to do that, rather than use an
existing component-oriented framework in a situation that warrants
that style. I'd also encourage you to think about why tens of
thousands of developers have chosen Struts as an action-oriented
framework when they too could have chosen a component-oriented
alternative if it fit their needs.

--
Martin Cooper


 We have DI
 in place, which is a good backbone for that.

 For example, look at this:

 class MyAction {
   @Inject
   MyComponent blub; // Implements StrutsComponent
 }

 body
   s2:component id=blub /
 /body

 Components might be able to return html. They can calculate. They can
 be used with JSP. Looking at this:
 http://tapestry.apache.org/component-reference.html

 We can learn a bit from Tapestry here. Probably we are able to reuse
 some of the components from them.

 I begin to think a good frontend layer would bring benefits. Otherwise
 it might happen S2 is more and more going into the direction service
 layer, and for that it might not fit very well.

 What do you think?

 Cheers
 Christian

 --
 http://www.grobmeier.de
 https://www.timeandbill.de


 --
 http://www.grobmeier.de
 https://www.timeandbill.de

 -
 To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
 For additional commands, e-mail: dev-h...@struts.apache.org


-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org



Re: Struts 2 Components

2012-01-26 Thread Łukasz Lenart
Hi,

After Martin's words, there is nothing to say. Adding components to S2
isn't a good option, S2 should remain as action base framework. If you
want components you have a lot of options - Wicket, JSF, Tapestry,
etc.


Kind regards
-- 
Łukasz

-
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org