wicket-web-action is a little library that makes it easier to decouple wicket pages from the rest of your application. It allows you to bind return values and actions of components instead of hard-coding them in your page class.

Consider the following wicket page:

public class SomePage extends WebPage {
    public SomePage() {
        /* ... */
        Label someLabel = new Label("grandTotal", "Not Applicable");
        someLabel.setVisible(false);
        add(someLabel);
    
        Button submitButton = new Button("submitButton") {
            @Override
            public void onSubmit() {
                someService.doSomeBusinessLogic();
            }
        };
        someForm.add(submitButton);
    }
}

This page class does not only provide the structure of the page, it also defines what data should be displayed and what should happen when the user interacts with the page. With wicket-web-action, you can separate these concerns:

import static net.davidtanzer.wicket.webbinding.WebBinding.*;
/* ... */

public class SomePage extends WebPage {
    @Inject SomePagePresentationModel presentationModel;

    public SomePage {
        /* ... */
        Label someLabel = bindable(Label.class, "grandTotal", 
            new PropertyModel<String>(presentationModel, "grandTotal"));
        bind(someLabel.isVisible()).to(presentationModel).isGrandTotalApplicable()
        add(someLabel);

        Button submitButton = bindable(Button.class, "submitButton");
        bindAction(presentationModel.submitAction()).when(submitButton).onSubmit();
        someForm.add(submitButton);
    }
}

You can find more information about how to use this library on the Github page of wicket-web-action. I will collect all my blog posts about this library here: wicket-web-action Resources.