Anchor

Hyperlinks to scroll on one page.

When To Use

  • For displaying anchor hyperlinks on page and jumping between them.

Basic

The simplest usage.

Static Anchor

Do not change state when page is scrolling.

Horizontal Anchor

Horizontally aligned anchors.

API Reference

Anchor

Property
Description
Type
Default

affix

Fixed mode of Anchor boolean true

bounds

Bounding distance of anchor area, unit: px number 5

offsetTop

Pixels to offset from top when calculating position of scroll number 0

targetOffset

Anchor scroll offset, default as offsetTop number -

container

Scrolling container selector string 'window'

direction

Set Anchor direction 'vertical' | 'horizontal' 'vertical'
Property
Description
Type
Default

href

target of hyperlink string -

title

content of hyperlink string -

target

Specifies where to display the linked URL string -