pippo-java / pippo

Micro Java Web Framework
http://www.pippo.ro
Apache License 2.0
786 stars 129 forks source link

Something similar with LiveWire #551

Open decebals opened 4 years ago

decebals commented 4 years ago

For a long time I have been thinking about how I could write a web application with as much UI code as possible in Java. I like the approach with rendering the HTML page on the server side and as little JavaScript as possible. I know about Wicket (I used in the past - it's a good library) and Vaadin. But I want something minimalist in Pippo style. If I use any JavaScript framework as VueJs, React or Angular to build a rich and responsible web application, then the server side (backend in Java) is very small (only the REST services) in comparison with the frontend (JavaScript), and I don't like that. That being said, I don't know if we couldn't introduce in Pippo some idea from:

I use [pippo-pebble] module for page rendering and I am satisfied. But the binding is in one direction (from Java to HTML) and I am missing the part with HTML to Java binding (when you submit a form or click on a button).

mhagnumdw commented 4 years ago

Hi!

I liked that idea. I also liked the video of the presentation.

I agree that it would be very nice for Pippo to have that option.

Would the implementation start from scratch? Or was it based on something already done? There is a good job to be done in javascript!

@decebals , do you have anything else in mind? If so, share it with us.

decebals commented 4 years ago

@mhagnumdw

Would the implementation start from scratch?

No, it's too much work for a small team like us.

Or was it based on something already done?

I think we can rely on the work done in the open source projects listed above. I'm thinking here about JavaScript, web sockets, and others. I wish only (if it's possible) to port the server side code from Laravel (PHP) to Pippo (Java). If we consider that this feature is valuable for us, we can talk with the teams that already implemented this concept in other languages.

@decebals , do you have anything else in mind? If so, share it with us. Other idea is described in #554.

Also other ideas that make Pippo a little bit more component oriented I think that are welcome. I use in my projects Pebble as template engine and with some addons (custom extensions and functions added in Pebble - see for example RouteExtension) you can simplify a lot the UI part.