/
githubmirror
/
bootstrap
Обзор
Документация
Войти
/
githubmirror
/
bootstrap
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
site/src/components/header/LinkItem.astro
24 строки
496 B
Julien Déramond
Docs: migration from Hugo to Astro (#41251)
15 апр 2025, 19:37
Не верифицирован
15 апр 2025, 19:37
a8ab199
Код
Авторство
О чём код?
--- interface Props { active?: boolean class?: string href: string rel?: HTMLAnchorElement['rel'] target?: HTMLAnchorElement['target'] track?: boolean } const { active, class: className, track, ...props } = Astro.props const content = await Astro.slots.render('default') --- <li class="nav-item col-6 col-lg-auto"> <a aria-current={active ? true : undefined} class:list={['nav-link py-2 px-0 px-lg-2', className, { active }]} {...props} > <slot /> </a> </li>