---
url: https://lit-ui-router.dev/reference/lit-ui-router/types/UiSrefOptions.md
---
[lit-ui-router](../index.md) / UiSrefOptions

# Interface: UiSrefOptions

Defined in: [packages/lit-ui-router/src/ui-sref.ts:98](https://github.com/simshanith/lit-ui-router/blob/740888c2b2ba358c4dfa52a122e927df6a604b12/packages/lit-ui-router/src/ui-sref.ts#L98)

Directive options for [uiSref](../directives/uiSref.md), passed alongside the transition
options in its third argument. These never reach `@uirouter/core`.

## Properties

| Property | Type | Description | Defined in |
| ------ | ------ | ------ | ------ |
|  `assignHref?` | `boolean` | `"auto"` | Where the generated `href` is written. - `true` *(default in 1.x)* — always write it, whatever the element is. This is the historical behaviour and the standing answer for a custom element that declares its own `href`. - `'auto'` — write it only to elements the HTML spec gives an `href`: `<a>`, `<area>`, and SVG `<a>`. This is the correct behaviour and becomes the default in 2.0. - `false` — never write it; the app manages the attribute itself. Under `true`, a non-link that receives an `href` warns once and names `'auto'` as the fix. This option governs the `href` attribute **only**. Whether the click handler defers to native browser behaviour is decided by the element itself, never by this setting — see `isNativeLink`. | [packages/lit-ui-router/src/ui-sref.ts:117](https://github.com/simshanith/lit-ui-router/blob/740888c2b2ba358c4dfa52a122e927df6a604b12/packages/lit-ui-router/src/ui-sref.ts#L117) |
