/
githubmirror
/
bootstrap
Обзор
Документация
Войти
/
githubmirror
/
bootstrap
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
site/astro.config.ts
41 строка
1 KB
Julien Déramond
Add astro-broken-links-checker to detect and fix broken internal links (#42178)
14 мар 2026, 00:26
Не верифицирован
14 мар 2026, 00:26
9e17504
Код
Авторство
О чём код?
import { defineConfig } from 'astro/config' import astroBrokenLinksChecker from 'astro-broken-links-checker' import { bootstrap } from './src/libs/astro' import { getConfig } from './src/libs/config' import { algoliaPlugin } from './src/plugins/algolia-plugin' import { stackblitzPlugin } from './src/plugins/stackblitz-plugin' const isDev = process.env.NODE_ENV === 'development' const site = isDev ? // In development mode, use the local dev server. 'http://localhost:9001' : process.env.DEPLOY_PRIME_URL !== undefined ? // If deploying on Netlify, use the `DEPLOY_PRIME_URL` environment variable. process.env.DEPLOY_PRIME_URL : // Otherwise, use the `baseURL` value defined in the `config.yml` file. getConfig().baseURL // https://astro.build/config export default defineConfig({ build: { assets: `docs/${getConfig().docs_version}/assets` }, integrations: [ bootstrap(), astroBrokenLinksChecker({ checkExternalLinks: false, cacheExternalLinks: false, throwError: true, linkCheckerDir: '.link-checker' }) ], markdown: { smartypants: false, syntaxHighlight: 'prism' }, site, vite: { plugins: [algoliaPlugin(), stackblitzPlugin()] } })