---
url: /reference/items/AnchorNav.md
---
# AnchorNav
## Usage
This component can be directly imported and defined as a dependency of your application:
```js
import { registerComponent } from '@studiometa/js-toolkit';
import { AnchorNav } from '@studiometa/ui';
registerComponent(AnchorNav);
```
Then in your html make sure to have similar id and href for the link and the target.
```html{16}
```
You can then add options from the [withTransition](/reference/items/Transition/#transition) and [withMountWhenInView](https://js-toolkit.studiometa.dev/api/decorators/withMountWhenInView.html):
```html{16}
```