Skip to content
Nalu
Open Source · Java 17 · GWT · J2CL

From routes
to applications.
Structure included.

Nalu brings structure to GWT and J2CL web applications. Connect a route to a controller, let the framework create the component and put it into a shell. Back, forward and reload work out of the box.

Apache 2.0   /   Hash and clean URLs   /   Any widget library   /   Annotation processor
Surfing penguin on a turquoise surfboard
@Application@Controller@ShellRouterFiltersCompositesEvent bus
Route. Controller. Component.

Less glue code.
More Java.

A route selects a controller. The controller loads data and handles events, the component renders the view. Nalu creates both, injects context, router and event bus, and manages their life cycle.

Connect a route to a controllerJava
// /shell/route/{parameter} shows MyComponent in the "content" slot
@Controller(route = "/shell/route/:id",
            selector = "content",
            componentInterface = IMyComponent.class,
            component = MyComponent.class)
public class MyController extends AbstractComponentController<...> {

  @AcceptParameter("id")
  public void setId(String id) { ... }
}

// Navigate from any controller
this.router.route("/shell/route/*", id);

Route based navigation

Routes carry the shell, the controller and its parameters. Nalu supports the browser history, links and programmatic routing.

Clean URLs

Choose hash based or hash-less URLs with one switch in the @Application annotation. A base path supports sub directories.

Controller life cycle

bind, start, activate, mayStop, unbind, deactivate and stop, with caching for controllers and composites.

Shells, composites, pop-ups

Several shells, composite controllers for smaller units, block controllers and pop-up controllers with conditions.

Filters and handlers

Filters intercept routings and redirect. Handlers react to events without a view. Handler registrations are removed automatically.

Your widget library

Plugins for GWT widgets, Elemental2, Elemento and Domino-UI 2. Nalu itself needs no GWT user library and is prepared for J2CL.

Start with a working setup

Dependencies, module descriptor, entry point, application, shell and a first controller.

Read the quickstart →

Understand routing

Routes, parameters, the router, filters and clean URLs with server configuration.

Read about routing →

Discover the API

Annotations, base classes, plugins, events, modules and more for release 4.0.2.

Open the reference →