Esc

COMARK0008 · warning

comark/duplicate-id

Give each element its own id

Two elements with one id. A link to #id goes to the first, so the second can't be linked to. Comark numbers a heading whose id is taken, so this is always an id written as {#id}.

Incorrect

## Setup

Install the duck counter.

## Pond setup {#setup}

Fill the pond.
md
lint-comark example.mdexample.md:5:15 comark/duplicate-idThe h2 on line 5 has the id setup, which an element before it already has, so links to #setup go to that one.Give it an id of its own, such as {#setup-2}.✖ 1 problem

Correct

## Setup

Install the duck counter.

## Pond setup {#pond-setup}

Fill the pond.
md
lint-comark example.md✔ No problems