Package-level declarations

Types

Link copied to clipboard

A base interface for routing builders. Provides methods to define routes, views, actions, and metadata.

Link copied to clipboard

An abstract base implementation of the BaseRoutingBuilder interface. Provides common functionality for routing builders.

Link copied to clipboard

A routing builder interface for numeric routes.

Link copied to clipboard

An implementation of the IntRoutingBuilder interface for numeric routes. Provides methods to define views and actions for routes with numeric parameters.

Link copied to clipboard

Represents a routing context that holds a numeric value.

Link copied to clipboard

Default implementation of IntRoutingContext. Holds a numeric value that can be accessed within the routing context.

Link copied to clipboard
interface Meta

Represents metadata for a web page, including title, description, author, and more.

Link copied to clipboard
@Serializable
class MetaImpl : Meta

Default implementation of the Meta interface.

Link copied to clipboard
@Serializable
data class OpenGraph(var title: String? = null, var description: String? = null, var images: List<OpenGraphImage>? = null, var type: String? = null, var url: String? = null, var locale: String? = null, var siteName: String? = null)

Represents Open Graph metadata for a web page.

Link copied to clipboard
@Serializable
data class OpenGraphImage(var url: String, var width: Int? = null, var height: Int? = null, var alt: String? = null)

Represents an Open Graph image with optional width, height, and alt text.

Link copied to clipboard

A routing builder interface for given path routes.

Link copied to clipboard

An implementation of the PlainRoutingBuilder interface for plain routes. Provides methods to define views and actions for routes without parameters.

Link copied to clipboard
@Serializable
data class Robots(var noindex: Boolean = false, var nofollow: Boolean = false, var noarchive: Boolean = false, var nosnippet: Boolean = false, var noimageindex: Boolean = false)

Represents robots meta tags for controlling indexing and crawling behavior.

Link copied to clipboard
sealed class Route

A model for an application route.

Link copied to clipboard

A routing builder interface for entry route.

Link copied to clipboard

An implementation of the RoutingBuilder interface for entry routes. Provides methods to define default content, metadata, views, and actions.

Link copied to clipboard
interface RoutingContext

Represents the context of a routing operation, providing access to the current path, remaining path and parameters.

Link copied to clipboard

Default implementation of RoutingContext. Provides properties for path, remaining path and parameters.

Link copied to clipboard

A marker for routing DSL.

Link copied to clipboard
class RoutingModel(val routes: List<Route>? = null, defaultContent: @Composable IComponent.() -> Unit? = null, val defaultMeta: Meta?, notFoundView: @Composable IComponent.() -> Unit? = null, notFoundAction: suspend () -> Unit? = null, val notFoundMeta: Meta?)

The routing tree model.

Link copied to clipboard

A routing builder interface for string routes.

Link copied to clipboard

An implementation of the StringRoutingBuilder interface for string routes. Provides methods to define views and actions for routes with string parameters.

Link copied to clipboard

Represents a routing context that holds a string value.

Link copied to clipboard

Default implementation of StringRoutingContext. Holds a string value that can be accessed within the routing context.

Properties

Link copied to clipboard
val DoneCallbackCompositionLocal: ProvidableCompositionLocal<() -> Unit?>
Link copied to clipboard

Provides the global router instance for use outside of composition.

Link copied to clipboard

Internal global router instance for use outside of composition. Do not use directly. Use Router.global instead.

Link copied to clipboard
val RoutingModelCompositionLocal: ProvidableCompositionLocal<RoutingModel>

CompositionLocal for providing the routing model instance.

Functions

Link copied to clipboard
@Composable
fun IComponent.browserRouter(initRoute: String = "/", contextPath: String = "", routing: RoutingBuilder.(RoutingContext) -> Unit)

Creates a BrowserRouter with the specified initial route and context path.

Link copied to clipboard
@Composable
fun IComponent.hashRouter(initRoute: String = "/", routing: RoutingBuilder.(RoutingContext) -> Unit)

Creates a HashRouter with the specified initial route.