Reference site / build (push) Canceled after 0s
Expose Rust Text View tokens and safely highlight signatures and JSON results. Add animated Interface and inline Run disclosures with a shared 10ms line cadence, typed argument inputs, and explicit execution. Update documentation and browser regressions for the new controls and explicit counter-value responses.
27 lines
1.0 KiB
JavaScript
27 lines
1.0 KiB
JavaScript
import './plugins/environment.mjs';
|
|
import { defineConfig } from 'astro/config';
|
|
import { unified } from '@astrojs/markdown-remark';
|
|
import documentLinks, { normalizeBase } from './plugins/document-links.mjs';
|
|
|
|
const base = normalizeBase(process.env.SITE_BASE || '/');
|
|
const site = process.env.SITE_URL || undefined;
|
|
if (site) {
|
|
const url = new URL(site);
|
|
if (!['http:', 'https:'].includes(url.protocol) || url.username || url.password || url.search || url.hash || url.pathname !== '/') {
|
|
throw new Error('SITE_URL must be an http(s) origin; use SITE_BASE for a path prefix');
|
|
}
|
|
}
|
|
|
|
export default defineConfig({
|
|
output: 'static',
|
|
site,
|
|
base,
|
|
trailingSlash: 'always',
|
|
// Browser tests exercise the site, not the development toolbar overlay.
|
|
devToolbar: { enabled: process.env.SITE_BROWSER_TEST !== '1' },
|
|
markdown: {
|
|
processor: unified({ remarkPlugins: [[documentLinks, { base }]], smartypants: false }),
|
|
shikiConfig: { themes: { light: 'github-light', dark: 'github-dark' }, langAlias: { wip: 'text' } },
|
|
},
|
|
});
|