core::link
Structs
Link
Navigates to a URL when its slotted content is clicked or tapped.
Link remains router-agnostic: it writes a URL, while Router and Route
declaratively read the current location. On web targets, same-origin
target=Current navigation can be serviced through client-side history
updates instead of a full document reload. Paths declared in Cargo metadata's
[package.metadata.pax.web].server_owned_prefixes use ordinary browser
navigation instead, preserving the query and fragment. The hosting server
must separately serve those paths. This web setting does not change native
routing or target=New behavior.
Properties
url
Type: Property<String>
Destination URL.
target
Type: Property<Target>
Whether to open the URL in the current or a new browsing context.
autosize
Type: Property<bool>
Automatically sizes the link wrapper to its slotted content when possible.
autosize_x
Type: Property<Option<bool>>
Optional override for whether autosize manages the x axis.
autosize_y
Type: Property<Option<bool>>
Optional override for whether autosize manages the y axis.
Enums
Target
Navigation target for Link.
Variants
Current
Navigate in the current window or tab.
New
Navigate in a new window or tab.