-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
separate into modules #36
Comments
Good idea. Just to throw in another perspective... we're rolling Soy templates out into a project heavily invested in JSP, which is requiring us to create wrapper Tag classes so old views can utilize the new templates. In order to utilize the same global and runtime models configured for the "new shit" I've based these tags on the renderer classes in soy-spring-view. FWIW. This would really help. |
I investigates this a bit while converting spring-soy-view to play-soy-view for play framework 2.x. I realized that it may be possible to do this but one would have to assume at least a dependency on Servlet API. At the moment my real life projects vary between play and spring-mvc and layer of separation I cannot achieve there thus making this for me abstract or an academic endeavor. As a side note, as not sure if you are aware, Play does not depend on servlet API at all. |
It would be awesome, generally speaking, to break the dependency on the Servlet API. What hard dependencies does spring-soy-view have on Servlet API? For example, in RenderRequest.java, could we use a Writer instead of a HttpServletResponse? I don't see that the HttpServletRequest is used anywhere but unit tests. |
Well, it requires some thinking, I remember I may have used this object also in RuntimeRenderers, they need to access various things like Cookies, etc. |
A no, I am looking at this now, technically it is not required right because RuntimeRenderes are invoked here in SoyView, which is a spring mvc specific class:
|
Unfortunately, having looked more into this I think it could maybe work only for servlet containers, in case of play, there are much more drastic changes that are needed, therefore it seems to be very hard to capture a generic abstraction. I think I will close this. Objections? |
It would be good if spring-mvc was just a plugin project, we could support other java/scala view technologies by having a generic core library. Experiment.
The text was updated successfully, but these errors were encountered: