mirror of
https://github.com/withastro/astro.git
synced 2024-12-23 21:53:55 -05:00
[ci] format
This commit is contained in:
parent
8530cce14f
commit
963100fb27
1 changed files with 5 additions and 5 deletions
|
@ -53,11 +53,11 @@ export default function createCollectHeaders() {
|
|||
node as any
|
||||
).value = `<${node.tagName} id={${node.properties.id}}>${raw}</${node.tagName}>`;
|
||||
} else {
|
||||
let slug = slugger.slug(text);
|
||||
let slug = slugger.slug(text);
|
||||
|
||||
if (slug.endsWith('-')) slug = slug.slice(0, -1);
|
||||
if (slug.endsWith('-')) slug = slug.slice(0, -1);
|
||||
|
||||
node.properties.id = slug;
|
||||
node.properties.id = slug;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue