You are viewing the Akan.js v1 docs.Go to the latest v2 docs

model.util.ts / [Model].Util.tsx

The Util module is a designated space for UI helpers, sub-components, and specific logic that supports your main application features. It is especially useful for packaging complex interactions, wrappers, and reusable logic to keep your 'Page' and 'Zone' files clean.
[Module].Util.tsx
Standard naming convention for module utilities.
Complex Logic
Encapsulate complex state management and store interactions.
Wrappers
Wrappers for server-side actions or navigation.

Packaging Complex Logic

When a feature requires local state (like Modals), form handling, and store interactions, encapsulate it in a Util component.
RefundModal Component

Wrapper for Server Actions

Use wrappers to handle client-side events that trigger server actions (via fetch) and navigation, while keeping children simpler.
CreateOrderWrapper

Endpoint Trigger Components

Simple button components that trigger specific business logic or endpoints.
ApproveButton

Context-Aware UI

Components that adapt their rendering based on the global store state (e.g. current path, user role).
ContextBackButton

Released under the MIT License

Connect your AI to these docs

MCPhttps://akanjs.com/mcp
Copyright © 2026 Akan.js All rights reserved.System managed bybassman