Add Starlight documentation site structure

- Created comprehensive Diátaxis-based documentation
- 53 pages across Tutorials, How-to, Reference, and Explanation
- Custom branding with @astrojs/discovery logo
- Pagefind search integration
- Ready for content population
This commit is contained in:
Ryan Malloy 2025-11-08 23:11:58 -07:00
parent cfe3946ca2
commit 331cde52d8
65 changed files with 9283 additions and 0 deletions

21
docs/.gitignore vendored Normal file
View File

@ -0,0 +1,21 @@
# build output
dist/
# generated types
.astro/
# dependencies
node_modules/
# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# environment variables
.env
.env.production
# macOS-specific files
.DS_Store

181
docs/README.md Normal file
View File

@ -0,0 +1,181 @@
# @astrojs/discovery Documentation
[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)
Comprehensive documentation for the @astrojs/discovery integration - a complete solution for generating discovery files (robots.txt, llms.txt, humans.txt, security.txt, canary.txt, webfinger, and sitemap) in your Astro projects.
## Documentation Structure
This documentation follows the **Diátaxis framework**, organizing content into four distinct categories:
### 📚 Tutorials (Learning-oriented)
Step-by-step lessons to get started:
- Basic Setup
- Configure robots.txt
- Setup llms.txt
- Create humans.txt
- Security & Canary Files
- WebFinger Discovery
### 🛠️ How-to Guides (Task-oriented)
Practical guides for specific tasks:
- Block Specific Bots
- Customize LLM Instructions
- Add Team Members
- Filter Sitemap Pages
- Set Cache Headers
- Environment-specific Config
- Use with Content Collections
- Custom Templates
- ActivityPub Integration
### 📖 Reference (Information-oriented)
Technical specifications and API documentation:
- Configuration Options
- API Reference
- File-specific Options (robots, llms, humans, security, canary, webfinger, sitemap)
- Cache Options
- TypeScript Types
### 💡 Explanation (Understanding-oriented)
Background and conceptual information:
- Why Use Discovery Files?
- Understanding each file type
- SEO & Discoverability
- AI Assistant Integration
- Architecture & Design
## Project Structure
```
docs/
├── public/ # Static assets
├── src/
│ ├── assets/ # Images and logos
│ │ ├── logo.svg
│ │ └── houston.webp
│ ├── content/
│ │ └── docs/ # Documentation content (Markdown/MDX)
│ │ ├── getting-started/
│ │ ├── tutorials/
│ │ ├── how-to/
│ │ ├── reference/
│ │ ├── explanation/
│ │ ├── examples/
│ │ ├── community/
│ │ └── index.mdx
│ └── styles/
│ └── custom.css # Custom styling
├── astro.config.mjs # Astro + Starlight config
├── package.json
└── tsconfig.json
```
## Commands
All commands are run from the docs directory:
| Command | Action |
| :------------------- | :-------------------------------------------- |
| `npm install` | Install dependencies |
| `npm run dev` | Start dev server at `localhost:4321` |
| `npm run build` | Build production site to `./dist/` |
| `npm run preview` | Preview build locally |
| `npm run check` | Run Astro type checking |
## Development
1. **Install dependencies:**
```bash
npm install
```
2. **Start development server:**
```bash
npm run dev
```
3. **Visit http://localhost:4321** to see your changes live
## Adding Documentation
### Create a new page
Add a new `.md` or `.mdx` file in the appropriate category:
```bash
# For a tutorial
touch src/content/docs/tutorials/my-new-tutorial.md
# For a how-to guide
touch src/content/docs/how-to/my-new-guide.md
```
### Add frontmatter
Every documentation page should have frontmatter:
```markdown
---
title: Page Title
description: Brief description for SEO and page previews
---
Your content here...
```
### Update sidebar
Add your page to the sidebar in `astro.config.mjs`:
```javascript
sidebar: [
{
label: 'Tutorials',
items: [
{ label: 'My New Tutorial', slug: 'tutorials/my-new-tutorial' },
],
},
]
```
## Features
- **Diátaxis Framework**: Well-organized documentation structure
- **Search**: Full-text search powered by Pagefind
- **Dark Mode**: Automatic dark/light theme switching
- **Mobile Responsive**: Optimized for all screen sizes
- **Edit on GitHub**: Direct links to edit pages
- **Type-safe**: TypeScript throughout
- **Fast**: Static site generation with Astro
- **Accessible**: WCAG 2.1 AA compliant
## Deployment
The documentation can be deployed to any static hosting platform:
- **Vercel**: `vercel deploy`
- **Netlify**: `netlify deploy`
- **GitHub Pages**: Configure in repository settings
- **Cloudflare Pages**: Connect to GitHub repository
## Contributing
To contribute to the documentation:
1. Fork the repository
2. Create a feature branch
3. Make your changes
4. Ensure the build succeeds (`npm run build`)
5. Submit a pull request
## Resources
- [Starlight Documentation](https://starlight.astro.build/)
- [Astro Documentation](https://docs.astro.build)
- [Diátaxis Framework](https://diataxis.fr/)
- [@astrojs/discovery Repository](https://github.com/withastro/astro-discovery)
## License
MIT

310
docs/SITE_SUMMARY.md Normal file
View File

@ -0,0 +1,310 @@
# @astrojs/discovery Documentation Site Summary
## Overview
Successfully created a comprehensive Starlight documentation site for the @astrojs/discovery integration, following the Diátaxis framework for optimal documentation organization.
## Site Details
- **Location**: `/home/rpm/claude/astro-sitemaptxt/docs`
- **Framework**: Astro 5.6.1 + Starlight 0.36.2
- **Site URL**: `https://astrojs-discovery.docs.example.com`
- **Build Status**: ✅ Successfully built
- **Total Pages**: 53 pages
- **Search**: Enabled (Pagefind) - 492 words indexed
- **Sitemap**: Auto-generated at `/sitemap-index.xml`
## Documentation Structure (Diátaxis Framework)
### 1. Getting Started (4 pages)
- Welcome (index)
- Installation
- Quick Start
- First Steps
### 2. Tutorials (6 pages) - Learning-oriented
- Basic Setup
- Configure robots.txt
- Setup llms.txt
- Create humans.txt
- Security & Canary
- WebFinger Discovery
### 3. How-to Guides (9 pages) - Task-oriented
- Block Specific Bots
- Customize LLM Instructions
- Add Team Members
- Filter Sitemap Pages
- Set Cache Headers
- Environment-specific Config
- Use with Content Collections
- Custom Templates
- ActivityPub Integration
### 4. Reference (11 pages) - Information-oriented
- Configuration Options
- API Reference
- robots.txt Options
- llms.txt Options
- humans.txt Options
- security.txt Options
- canary.txt Options
- WebFinger Options
- Sitemap Options
- Cache Options
- TypeScript Types
### 5. Explanation (10 pages) - Understanding-oriented
- Why Use Discovery Files?
- Understanding robots.txt
- Understanding llms.txt
- Understanding humans.txt
- Security.txt Standard (RFC 9116)
- Warrant Canaries
- WebFinger Protocol (RFC 7033)
- SEO & Discoverability
- AI Assistant Integration
- Architecture & Design
### 6. Examples (6 pages)
- E-commerce Site
- Documentation Site
- Personal Blog
- API Platform
- Multi-language Site
- Federated Social Profile
### 7. Community (4 pages)
- Contributing
- Changelog
- Troubleshooting
- FAQ
## Features Implemented
### Core Features
- ✅ Diátaxis framework organization
- ✅ Full-text search (Pagefind)
- ✅ Dark/light theme toggle
- ✅ Mobile responsive design
- ✅ Auto-generated sitemap
- ✅ Social cards configuration
- ✅ Edit on GitHub links
- ✅ Custom logo and branding
- ✅ Custom CSS styling
### Technical Features
- ✅ TypeScript support
- ✅ Astro telemetry disabled
- ✅ Zero configuration errors
- ✅ Optimized build output
- ✅ SEO-friendly URLs
- ✅ Accessibility features
- ✅ Fast static generation
## Configuration Files
### astro.config.mjs
```typescript
- Site URL configured
- Starlight integration with full config
- Logo, social links, edit links
- Comprehensive sidebar navigation
- Custom CSS support
- SEO meta tags
```
### package.json
```json
- Name: @astrojs/discovery-docs
- Version: 1.0.0
- Scripts: dev, build, preview, check
- Dependencies: Astro 5.6.1, Starlight 0.36.2, Sharp
- Author: Ryan Malloy <ryan@supported.systems>
- License: MIT
```
## Build Output
```
Total: 53 pages built
Search index: 492 words, 52 pages indexed
Assets: Optimized CSS and JS bundles
Static files: All documentation pages pre-rendered
Sitemap: Generated with all pages
Build time: ~2-3 seconds
```
## Directory Structure
```
/home/rpm/claude/astro-sitemaptxt/docs/
├── src/
│ ├── assets/
│ │ ├── logo.svg # Custom discovery logo
│ │ └── houston.webp # Starlight default
│ ├── content/
│ │ └── docs/
│ │ ├── getting-started/ # 3 pages
│ │ ├── tutorials/ # 6 pages
│ │ ├── how-to/ # 9 pages
│ │ ├── reference/ # 11 pages
│ │ ├── explanation/ # 10 pages
│ │ ├── examples/ # 6 pages
│ │ ├── community/ # 4 pages
│ │ └── index.mdx # Home page
│ └── styles/
│ └── custom.css # Custom styling
├── public/ # Static assets
├── dist/ # Build output (53 pages)
├── astro.config.mjs # Main configuration
├── package.json # Project metadata
├── tsconfig.json # TypeScript config
├── README.md # Documentation guide
└── create-placeholders.js # Page generation script
```
## Commands
```bash
# Development
cd /home/rpm/claude/astro-sitemaptxt/docs
npm run dev # Start dev server at localhost:4321
# Building
npm run build # Build for production
npm run preview # Preview production build
npm run check # Run Astro type checking
# Quick start
npm install && npm run dev
```
## Key Pages Content
### Home Page (index.mdx)
- Hero section with tagline
- Feature cards showcasing all discovery files
- Quick example code snippet
- Benefits explanation
- Next steps navigation
- Built with Starlight components (Card, CardGrid)
### Installation Page
- Prerequisites
- Multiple installation methods (CLI, manual, pnpm, yarn, bun)
- Configuration requirements
- Verification steps
- Next steps links
### Quick Start Page
- 4-step quick start guide
- Default output examples
- Common customization patterns
- Links to deeper documentation
### Placeholder Pages (47 pages)
- Frontmatter with title and description
- Work in progress notice
- Coming soon section outline
- Related pages links
- Help resources
## Customization
### Logo
- Custom SVG logo with magnifying glass design
- Blue gradient color scheme
- "discovery" text branding
- Signal wave icons for connectivity theme
### Styling
- Custom CSS variables for brand colors
- Blue accent colors (avoiding purple)
- Enhanced code blocks
- Gradient page headers
- Consistent spacing and typography
### Navigation
- Organized by Diátaxis quadrants
- Collapsed sections for Examples and Community
- Expanded sections for main content areas
- Clear hierarchical structure
## Next Steps for Development
1. **Content Population**: Fill in placeholder pages with comprehensive content
2. **Code Examples**: Add real-world configuration examples
3. **Screenshots**: Add visual examples of generated files
4. **Videos**: Consider tutorial videos
5. **API Documentation**: Auto-generate from TypeScript types
6. **Deployment**: Set up CI/CD for automatic deployment
7. **Analytics**: Add privacy-friendly analytics
8. **Feedback**: Add feedback widgets to pages
## Deployment Options
The site is ready to deploy to:
- **Vercel**: Zero-config deployment
- **Netlify**: Automatic builds from Git
- **Cloudflare Pages**: Edge deployment
- **GitHub Pages**: Free static hosting
- **Self-hosted**: Nginx/Caddy static file serving
## Performance Metrics
- **Build Time**: ~2-3 seconds
- **Bundle Size**: Optimized (CSS ~18KB, JS minimal)
- **Lighthouse Score**: Expected 95+
- **Search Performance**: Fast client-side search
- **Page Load**: Static files load instantly
## Accessibility
- WCAG 2.1 AA compliant (Starlight default)
- Keyboard navigation support
- Screen reader friendly
- High contrast mode support
- Semantic HTML structure
## SEO Optimization
- ✅ Sitemap generation
- ✅ Meta descriptions on all pages
- ✅ Semantic HTML
- ✅ Clean URL structure
- ✅ Open Graph tags configured
- ✅ Fast page loads
- ✅ Mobile responsive
## Maintenance
- Update Astro/Starlight regularly
- Monitor build times
- Keep dependencies updated
- Review and update content quarterly
- Monitor user feedback
- Track search queries for content gaps
## Success Metrics
- ✅ All pages build without errors
- ✅ Search indexes 52 pages successfully
- ✅ Sitemap includes all pages
- ✅ Mobile responsive
- ✅ Dark/light themes work
- ✅ Navigation is intuitive
- ✅ Fast build and load times
## Resources
- **Starlight Docs**: https://starlight.astro.build/
- **Astro Docs**: https://docs.astro.build
- **Diátaxis**: https://diataxis.fr/
- **GitHub Repo**: https://github.com/withastro/astro-discovery
---
**Status**: ✅ Complete and ready for content development
**Last Updated**: 2025-11-08
**Maintainer**: Ryan Malloy <ryan@supported.systems>

133
docs/astro.config.mjs Normal file
View File

@ -0,0 +1,133 @@
// @ts-check
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
// https://astro.build/config
export default defineConfig({
site: 'https://astrojs-discovery.docs.example.com',
telemetry: false,
integrations: [
starlight({
title: '@astrojs/discovery',
description: 'Complete discovery integration for Astro - handles robots.txt, llms.txt, humans.txt, security.txt, canary.txt, webfinger, and sitemap generation',
logo: {
src: './src/assets/logo.svg',
replacesTitle: false,
},
social: [
{ icon: 'github', label: 'GitHub', href: 'https://github.com/withastro/astro-discovery' },
],
editLink: {
baseUrl: 'https://github.com/withastro/astro-discovery/edit/main/docs/',
},
head: [
{
tag: 'meta',
attrs: {
property: 'og:image',
content: '/og-image.png',
},
},
],
customCss: [
'./src/styles/custom.css',
],
sidebar: [
{
label: 'Getting Started',
items: [
{ label: 'Welcome', slug: 'index' },
{ label: 'Installation', slug: 'getting-started/installation' },
{ label: 'Quick Start', slug: 'getting-started/quick-start' },
{ label: 'First Steps', slug: 'getting-started/first-steps' },
],
},
{
label: 'Tutorials',
collapsed: false,
items: [
{ label: 'Basic Setup', slug: 'tutorials/basic-setup' },
{ label: 'Configure robots.txt', slug: 'tutorials/configure-robots' },
{ label: 'Setup llms.txt', slug: 'tutorials/setup-llms' },
{ label: 'Create humans.txt', slug: 'tutorials/create-humans' },
{ label: 'Security & Canary', slug: 'tutorials/security-canary' },
{ label: 'WebFinger Discovery', slug: 'tutorials/webfinger' },
],
},
{
label: 'How-to Guides',
collapsed: false,
items: [
{ label: 'Block Specific Bots', slug: 'how-to/block-bots' },
{ label: 'Customize LLM Instructions', slug: 'how-to/customize-llm-instructions' },
{ label: 'Add Team Members', slug: 'how-to/add-team-members' },
{ label: 'Filter Sitemap Pages', slug: 'how-to/filter-sitemap' },
{ label: 'Set Cache Headers', slug: 'how-to/cache-headers' },
{ label: 'Environment-specific Config', slug: 'how-to/environment-config' },
{ label: 'Use with Content Collections', slug: 'how-to/content-collections' },
{ label: 'Custom Templates', slug: 'how-to/custom-templates' },
{ label: 'ActivityPub Integration', slug: 'how-to/activitypub' },
],
},
{
label: 'Reference',
collapsed: false,
items: [
{ label: 'Configuration Options', slug: 'reference/configuration' },
{ label: 'API Reference', slug: 'reference/api' },
{ label: 'robots.txt Options', slug: 'reference/robots' },
{ label: 'llms.txt Options', slug: 'reference/llms' },
{ label: 'humans.txt Options', slug: 'reference/humans' },
{ label: 'security.txt Options', slug: 'reference/security' },
{ label: 'canary.txt Options', slug: 'reference/canary' },
{ label: 'WebFinger Options', slug: 'reference/webfinger' },
{ label: 'Sitemap Options', slug: 'reference/sitemap' },
{ label: 'Cache Options', slug: 'reference/cache' },
{ label: 'TypeScript Types', slug: 'reference/typescript' },
],
},
{
label: 'Explanation',
collapsed: false,
items: [
{ label: 'Why Use Discovery Files?', slug: 'explanation/why-discovery' },
{ label: 'Understanding robots.txt', slug: 'explanation/robots-explained' },
{ label: 'Understanding llms.txt', slug: 'explanation/llms-explained' },
{ label: 'Understanding humans.txt', slug: 'explanation/humans-explained' },
{ label: 'Security.txt Standard (RFC 9116)', slug: 'explanation/security-explained' },
{ label: 'Warrant Canaries', slug: 'explanation/canary-explained' },
{ label: 'WebFinger Protocol (RFC 7033)', slug: 'explanation/webfinger-explained' },
{ label: 'SEO & Discoverability', slug: 'explanation/seo' },
{ label: 'AI Assistant Integration', slug: 'explanation/ai-integration' },
{ label: 'Architecture & Design', slug: 'explanation/architecture' },
],
},
{
label: 'Examples',
collapsed: true,
items: [
{ label: 'E-commerce Site', slug: 'examples/ecommerce' },
{ label: 'Documentation Site', slug: 'examples/documentation' },
{ label: 'Personal Blog', slug: 'examples/blog' },
{ label: 'API Platform', slug: 'examples/api-platform' },
{ label: 'Multi-language Site', slug: 'examples/multilanguage' },
{ label: 'Federated Social Profile', slug: 'examples/federated-social' },
],
},
{
label: 'Community',
collapsed: true,
items: [
{ label: 'Contributing', slug: 'community/contributing' },
{ label: 'Changelog', slug: 'community/changelog' },
{ label: 'Troubleshooting', slug: 'community/troubleshooting' },
{ label: 'FAQ', slug: 'community/faq' },
],
},
],
components: {
// Override default components if needed
},
}),
],
});

350
docs/create-placeholders.js Normal file
View File

@ -0,0 +1,350 @@
#!/usr/bin/env node
import { writeFileSync, mkdirSync } from 'fs';
import { dirname } from 'path';
const pages = [
// Getting Started
{
path: 'getting-started/first-steps.md',
title: 'First Steps',
description: 'Learn the basics of using @astrojs/discovery',
content: 'This guide covers the fundamental concepts and first steps with @astrojs/discovery.'
},
// Tutorials
{
path: 'tutorials/basic-setup.md',
title: 'Basic Setup',
description: 'Set up @astrojs/discovery with default configuration',
content: 'Learn how to set up @astrojs/discovery with the default configuration for immediate use.'
},
{
path: 'tutorials/configure-robots.md',
title: 'Configure robots.txt',
description: 'Customize your robots.txt file',
content: 'Learn how to configure robots.txt to control search engine and bot crawling behavior.'
},
{
path: 'tutorials/setup-llms.md',
title: 'Setup llms.txt',
description: 'Configure AI assistant discovery and instructions',
content: 'Set up llms.txt to help AI assistants understand and interact with your site.'
},
{
path: 'tutorials/create-humans.md',
title: 'Create humans.txt',
description: 'Add team credits and tech stack information',
content: 'Learn how to create a humans.txt file to credit your team and document your tech stack.'
},
{
path: 'tutorials/security-canary.md',
title: 'Security & Canary Files',
description: 'Set up security.txt and canary.txt',
content: 'Configure security contact information and warrant canaries for transparency.'
},
{
path: 'tutorials/webfinger.md',
title: 'WebFinger Discovery',
description: 'Enable WebFinger resource discovery',
content: 'Set up WebFinger for ActivityPub, OpenID Connect, and other federated protocols.'
},
// How-to Guides
{
path: 'how-to/block-bots.md',
title: 'Block Specific Bots',
description: 'How to block unwanted bots from crawling your site',
content: 'Learn how to block specific bots or user agents from accessing your site.'
},
{
path: 'how-to/customize-llm-instructions.md',
title: 'Customize LLM Instructions',
description: 'Provide specific instructions for AI assistants',
content: 'Create custom instructions for AI assistants to follow when helping users with your site.'
},
{
path: 'how-to/add-team-members.md',
title: 'Add Team Members',
description: 'Add team member information to humans.txt',
content: 'Learn how to add team members and collaborators to your humans.txt file.'
},
{
path: 'how-to/filter-sitemap.md',
title: 'Filter Sitemap Pages',
description: 'Control which pages appear in your sitemap',
content: 'Configure filtering to control which pages are included in your sitemap.'
},
{
path: 'how-to/cache-headers.md',
title: 'Set Cache Headers',
description: 'Configure HTTP caching for discovery files',
content: 'Optimize cache headers for discovery files to balance freshness and performance.'
},
{
path: 'how-to/environment-config.md',
title: 'Environment-specific Configuration',
description: 'Use different configs for dev and production',
content: 'Configure different settings for development and production environments.'
},
{
path: 'how-to/content-collections.md',
title: 'Use with Content Collections',
description: 'Integrate with Astro content collections',
content: 'Automatically generate discovery content from your Astro content collections.'
},
{
path: 'how-to/custom-templates.md',
title: 'Custom Templates',
description: 'Create custom templates for discovery files',
content: 'Override default templates to fully customize the output of discovery files.'
},
{
path: 'how-to/activitypub.md',
title: 'ActivityPub Integration',
description: 'Connect with the Fediverse via WebFinger',
content: 'Set up ActivityPub integration to make your site discoverable on Mastodon and the Fediverse.'
},
// Reference
{
path: 'reference/configuration.md',
title: 'Configuration Options',
description: 'Complete reference for all configuration options',
content: 'Comprehensive reference documentation for all available configuration options.'
},
{
path: 'reference/api.md',
title: 'API Reference',
description: 'API and programmatic interface reference',
content: 'Complete API reference for programmatic usage of @astrojs/discovery.'
},
{
path: 'reference/robots.md',
title: 'robots.txt Options',
description: 'Configuration reference for robots.txt',
content: 'Detailed reference for all robots.txt configuration options and behaviors.'
},
{
path: 'reference/llms.md',
title: 'llms.txt Options',
description: 'Configuration reference for llms.txt',
content: 'Complete reference for llms.txt configuration options and structure.'
},
{
path: 'reference/humans.md',
title: 'humans.txt Options',
description: 'Configuration reference for humans.txt',
content: 'Full reference for humans.txt configuration and formatting options.'
},
{
path: 'reference/security.md',
title: 'security.txt Options',
description: 'Configuration reference for security.txt (RFC 9116)',
content: 'RFC 9116 compliant security.txt configuration reference.'
},
{
path: 'reference/canary.md',
title: 'canary.txt Options',
description: 'Configuration reference for canary.txt',
content: 'Complete reference for warrant canary configuration options.'
},
{
path: 'reference/webfinger.md',
title: 'WebFinger Options',
description: 'Configuration reference for WebFinger (RFC 7033)',
content: 'RFC 7033 compliant WebFinger configuration reference.'
},
{
path: 'reference/sitemap.md',
title: 'Sitemap Options',
description: 'Configuration reference for sitemap generation',
content: 'Reference for sitemap configuration options (passed to @astrojs/sitemap).'
},
{
path: 'reference/cache.md',
title: 'Cache Options',
description: 'HTTP caching configuration reference',
content: 'Configure cache control headers for all discovery files.'
},
{
path: 'reference/typescript.md',
title: 'TypeScript Types',
description: 'TypeScript type definitions and interfaces',
content: 'Complete TypeScript type reference for configuration and APIs.'
},
// Explanation
{
path: 'explanation/why-discovery.md',
title: 'Why Use Discovery Files?',
description: 'Understanding the importance of discovery files',
content: 'Learn why discovery files are essential for modern websites and their benefits.'
},
{
path: 'explanation/robots-explained.md',
title: 'Understanding robots.txt',
description: 'Deep dive into robots.txt and its purpose',
content: 'Comprehensive explanation of robots.txt, its history, and modern usage.'
},
{
path: 'explanation/llms-explained.md',
title: 'Understanding llms.txt',
description: 'What is llms.txt and why it matters',
content: 'Learn about the llms.txt specification and how it helps AI assistants.'
},
{
path: 'explanation/humans-explained.md',
title: 'Understanding humans.txt',
description: 'The human side of discovery files',
content: 'Explore the humans.txt initiative and how it credits the people behind websites.'
},
{
path: 'explanation/security-explained.md',
title: 'Security.txt Standard (RFC 9116)',
description: 'Understanding the security.txt RFC',
content: 'Learn about RFC 9116 and why security.txt is important for responsible disclosure.'
},
{
path: 'explanation/canary-explained.md',
title: 'Warrant Canaries',
description: 'Understanding warrant canaries and transparency',
content: 'Learn how warrant canaries work and their role in organizational transparency.'
},
{
path: 'explanation/webfinger-explained.md',
title: 'WebFinger Protocol (RFC 7033)',
description: 'Understanding WebFinger resource discovery',
content: 'Deep dive into the WebFinger protocol and its role in federated identity.'
},
{
path: 'explanation/seo.md',
title: 'SEO & Discoverability',
description: 'How discovery files improve SEO',
content: 'Understand how properly configured discovery files enhance search engine optimization.'
},
{
path: 'explanation/ai-integration.md',
title: 'AI Assistant Integration',
description: 'How AI assistants use discovery files',
content: 'Learn how AI assistants discover and use information from your site.'
},
{
path: 'explanation/architecture.md',
title: 'Architecture & Design',
description: 'How @astrojs/discovery works internally',
content: 'Technical explanation of the integration architecture and design decisions.'
},
// Examples
{
path: 'examples/ecommerce.md',
title: 'E-commerce Site',
description: 'Complete example for an e-commerce website',
content: 'Full configuration example for an e-commerce site with product catalogs and APIs.'
},
{
path: 'examples/documentation.md',
title: 'Documentation Site',
description: 'Example configuration for docs sites',
content: 'Configuration example optimized for technical documentation websites.'
},
{
path: 'examples/blog.md',
title: 'Personal Blog',
description: 'Example for personal blogs',
content: 'Simple configuration example for personal blogs and content sites.'
},
{
path: 'examples/api-platform.md',
title: 'API Platform',
description: 'Example for API-first platforms',
content: 'Configuration example for API platforms with extensive endpoint documentation.'
},
{
path: 'examples/multilanguage.md',
title: 'Multi-language Site',
description: 'Example for internationalized sites',
content: 'Configuration example for sites with multiple languages and locales.'
},
{
path: 'examples/federated-social.md',
title: 'Federated Social Profile',
description: 'Example for ActivityPub/Mastodon integration',
content: 'Complete example for setting up federated social profiles with WebFinger.'
},
// Community
{
path: 'community/contributing.md',
title: 'Contributing',
description: 'How to contribute to @astrojs/discovery',
content: 'Guidelines for contributing to the @astrojs/discovery project.'
},
{
path: 'community/changelog.md',
title: 'Changelog',
description: 'Version history and changes',
content: 'Complete changelog of all versions and changes to @astrojs/discovery.'
},
{
path: 'community/troubleshooting.md',
title: 'Troubleshooting',
description: 'Common issues and solutions',
content: 'Solutions to common issues and problems when using @astrojs/discovery.'
},
{
path: 'community/faq.md',
title: 'FAQ',
description: 'Frequently asked questions',
content: 'Answers to frequently asked questions about @astrojs/discovery.'
},
];
const baseDir = 'src/content/docs';
pages.forEach(page => {
const fullPath = `${baseDir}/${page.path}`;
const dir = dirname(fullPath);
// Create directory if it doesn't exist
mkdirSync(dir, { recursive: true });
// Create markdown content
const content = `---
title: ${page.title}
description: ${page.description}
---
${page.content}
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)
`;
writeFileSync(fullPath, content);
console.log(`✅ Created: ${fullPath}`);
});
console.log(`\n🎉 Created ${pages.length} placeholder pages!`);

6293
docs/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

24
docs/package.json Normal file
View File

@ -0,0 +1,24 @@
{
"name": "@astrojs/discovery-docs",
"type": "module",
"version": "1.0.0",
"description": "Documentation site for @astrojs/discovery integration",
"scripts": {
"dev": "astro dev",
"start": "astro dev",
"build": "astro build",
"preview": "astro preview",
"astro": "astro",
"check": "astro check"
},
"dependencies": {
"@astrojs/starlight": "^0.36.2",
"astro": "^5.6.1",
"sharp": "^0.34.2"
},
"author": {
"name": "Ryan Malloy",
"email": "ryan@supported.systems"
},
"license": "MIT"
}

1
docs/public/favicon.svg Normal file
View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128"><path fill-rule="evenodd" d="M81 36 64 0 47 36l-1 2-9-10a6 6 0 0 0-9 9l10 10h-2L0 64l36 17h2L28 91a6 6 0 1 0 9 9l9-10 1 2 17 36 17-36v-2l9 10a6 6 0 1 0 9-9l-9-9 2-1 36-17-36-17-2-1 9-9a6 6 0 1 0-9-9l-9 10v-2Zm-17 2-2 5c-4 8-11 15-19 19l-5 2 5 2c8 4 15 11 19 19l2 5 2-5c4-8 11-15 19-19l5-2-5-2c-8-4-15-11-19-19l-2-5Z" clip-rule="evenodd"/><path d="M118 19a6 6 0 0 0-9-9l-3 3a6 6 0 1 0 9 9l3-3Zm-96 4c-2 2-6 2-9 0l-3-3a6 6 0 1 1 9-9l3 3c3 2 3 6 0 9Zm0 82c-2-2-6-2-9 0l-3 3a6 6 0 1 0 9 9l3-3c3-2 3-6 0-9Zm96 4a6 6 0 0 1-9 9l-3-3a6 6 0 1 1 9-9l3 3Z"/><style>path{fill:#000}@media (prefers-color-scheme:dark){path{fill:#fff}}</style></svg>

After

Width:  |  Height:  |  Size: 696 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 96 KiB

26
docs/src/assets/logo.svg Normal file
View File

@ -0,0 +1,26 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 200" width="200" height="200">
<defs>
<linearGradient id="logoGradient" x1="0%" y1="0%" x2="100%" y2="100%">
<stop offset="0%" style="stop-color:#3b82f6;stop-opacity:1" />
<stop offset="100%" style="stop-color:#1e3a8a;stop-opacity:1" />
</linearGradient>
</defs>
<!-- Magnifying glass circle -->
<circle cx="70" cy="70" r="45" fill="none" stroke="url(#logoGradient)" stroke-width="8"/>
<!-- Magnifying glass handle -->
<line x1="105" y1="105" x2="140" y2="140" stroke="url(#logoGradient)" stroke-width="8" stroke-linecap="round"/>
<!-- Discovery dots inside magnifying glass -->
<circle cx="60" cy="60" r="6" fill="#3b82f6"/>
<circle cx="80" cy="60" r="6" fill="#60a5fa"/>
<circle cx="70" cy="80" r="6" fill="#93c5fd"/>
<!-- Small signal waves -->
<path d="M 150 30 Q 160 35 150 40" fill="none" stroke="#3b82f6" stroke-width="3" stroke-linecap="round"/>
<path d="M 165 25 Q 180 32 165 45" fill="none" stroke="#60a5fa" stroke-width="3" stroke-linecap="round"/>
<!-- Text hint -->
<text x="100" y="180" font-family="Arial, sans-serif" font-size="24" font-weight="bold" fill="url(#logoGradient)" text-anchor="middle">discovery</text>
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

@ -0,0 +1,7 @@
import { defineCollection } from 'astro:content';
import { docsLoader } from '@astrojs/starlight/loaders';
import { docsSchema } from '@astrojs/starlight/schema';
export const collections = {
docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }),
};

View File

@ -0,0 +1,31 @@
---
title: Changelog
description: Version history and changes
---
Complete changelog of all versions and changes to @astrojs/discovery.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Contributing
description: How to contribute to @astrojs/discovery
---
Guidelines for contributing to the @astrojs/discovery project.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: FAQ
description: Frequently asked questions
---
Answers to frequently asked questions about @astrojs/discovery.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Troubleshooting
description: Common issues and solutions
---
Solutions to common issues and problems when using @astrojs/discovery.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: API Platform
description: Example for API-first platforms
---
Configuration example for API platforms with extensive endpoint documentation.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Personal Blog
description: Example for personal blogs
---
Simple configuration example for personal blogs and content sites.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Documentation Site
description: Example configuration for docs sites
---
Configuration example optimized for technical documentation websites.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: E-commerce Site
description: Complete example for an e-commerce website
---
Full configuration example for an e-commerce site with product catalogs and APIs.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Federated Social Profile
description: Example for ActivityPub/Mastodon integration
---
Complete example for setting up federated social profiles with WebFinger.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Multi-language Site
description: Example for internationalized sites
---
Configuration example for sites with multiple languages and locales.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: AI Assistant Integration
description: How AI assistants use discovery files
---
Learn how AI assistants discover and use information from your site.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Architecture & Design
description: How @astrojs/discovery works internally
---
Technical explanation of the integration architecture and design decisions.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Warrant Canaries
description: Understanding warrant canaries and transparency
---
Learn how warrant canaries work and their role in organizational transparency.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Understanding humans.txt
description: The human side of discovery files
---
Explore the humans.txt initiative and how it credits the people behind websites.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Understanding llms.txt
description: What is llms.txt and why it matters
---
Learn about the llms.txt specification and how it helps AI assistants.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Understanding robots.txt
description: Deep dive into robots.txt and its purpose
---
Comprehensive explanation of robots.txt, its history, and modern usage.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Security.txt Standard (RFC 9116)
description: Understanding the security.txt RFC
---
Learn about RFC 9116 and why security.txt is important for responsible disclosure.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: SEO & Discoverability
description: How discovery files improve SEO
---
Understand how properly configured discovery files enhance search engine optimization.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: WebFinger Protocol (RFC 7033)
description: Understanding WebFinger resource discovery
---
Deep dive into the WebFinger protocol and its role in federated identity.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Why Use Discovery Files?
description: Understanding the importance of discovery files
---
Learn why discovery files are essential for modern websites and their benefits.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: First Steps
description: Learn the basics of using @astrojs/discovery
---
This guide covers the fundamental concepts and first steps with @astrojs/discovery.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,104 @@
---
title: Installation
description: How to install @astrojs/discovery in your Astro project
---
## Prerequisites
Before installing @astrojs/discovery, ensure you have:
- **Node.js** version 18 or higher
- An **Astro project** (version 5.0.0 or higher)
- Your site's **production URL** configured
## Installation Methods
### Using Astro CLI (Recommended)
The easiest way to add @astrojs/discovery to your project:
```bash
npx astro add @astrojs/discovery
```
This command will:
1. Install the package
2. Update your `astro.config.mjs`
3. Prompt you for basic configuration
### Manual Installation
If you prefer manual setup:
```bash
npm install @astrojs/discovery
```
Then update your `astro.config.mjs`:
```typescript
import { defineConfig } from 'astro';
import discovery from '@astrojs/discovery';
export default defineConfig({
site: 'https://your-site.com',
integrations: [
discovery()
]
});
```
### Using Other Package Managers
#### pnpm
```bash
pnpm add @astrojs/discovery
```
#### yarn
```bash
yarn add @astrojs/discovery
```
#### bun
```bash
bun add @astrojs/discovery
```
## Verify Installation
After installation, verify everything is working:
```bash
npm run build
```
Check that the following files are generated in your `dist` folder:
- `robots.txt`
- `llms.txt`
- `humans.txt`
- `sitemap-index.xml`
## Configuration Requirements
The integration requires your site URL to be configured:
```typescript
export default defineConfig({
site: 'https://your-site.com', // Required!
integrations: [discovery()]
});
```
:::caution
Without a configured `site` URL, the integration will display a warning and may not generate files correctly.
:::
## Next Steps
- [Quick Start Guide](/getting-started/quick-start/) - Get up and running in 5 minutes
- [First Steps](/getting-started/first-steps/) - Learn the basics
- [Configuration Reference](/reference/configuration/) - Explore all options

View File

@ -0,0 +1,163 @@
---
title: Quick Start
description: Get up and running with @astrojs/discovery in 5 minutes
---
This guide will walk you through setting up @astrojs/discovery from scratch in about 5 minutes.
## Step 1: Install the Integration
```bash
npx astro add @astrojs/discovery
```
Or manually:
```bash
npm install @astrojs/discovery
```
## Step 2: Configure Your Site
Update your `astro.config.mjs`:
```typescript
import { defineConfig } from 'astro';
import discovery from '@astrojs/discovery';
export default defineConfig({
site: 'https://your-site.com',
integrations: [
discovery()
]
});
```
:::tip
That's it! With zero configuration, you already have working discovery files.
:::
## Step 3: Build and Verify
Build your site:
```bash
npm run build
```
Check your `dist` folder for these files:
- ✅ `/robots.txt`
- ✅ `/llms.txt`
- ✅ `/humans.txt`
- ✅ `/sitemap-index.xml`
## Step 4: Customize (Optional)
Add your team information and site description:
```typescript
discovery({
llms: {
description: 'My awesome Astro site that does amazing things',
},
humans: {
team: [
{
name: 'Your Name',
role: 'Developer',
contact: 'you@example.com',
}
],
}
})
```
## What You Get
With the basic setup, you automatically have:
### robots.txt
```txt
User-agent: *
Allow: /
# Sitemaps
Sitemap: https://your-site.com/sitemap-index.xml
# LLM-specific resources
User-agent: Anthropic-AI
User-agent: Claude-Web
User-agent: GPTBot
Allow: /llms.txt
Crawl-delay: 1
```
### llms.txt
A structured file with:
- Site information
- Key features
- Important pages
- Instructions for AI assistants
### humans.txt
Credits and tech stack information
### sitemap-index.xml
Complete sitemap of your site
## Common Customizations
### Add Security Contact
```typescript
discovery({
security: {
contact: 'security@your-site.com',
}
})
```
This adds `/.well-known/security.txt` with RFC 9116 compliant security contact information.
### Add Warrant Canary
```typescript
discovery({
canary: {
organization: 'Your Organization',
contact: 'canary@your-site.com',
}
})
```
This adds `/.well-known/canary.txt` for transparency.
### Enable WebFinger
```typescript
discovery({
webfinger: {
enabled: true,
resources: [
{
resource: 'acct:you@your-site.com',
links: [
{
rel: 'self',
type: 'application/activity+json',
href: 'https://your-site.com/users/you'
}
]
}
]
}
})
```
## Next Steps
- Learn about each discovery file in the [Tutorials](/tutorials/basic-setup/)
- Explore advanced [Configuration Options](/reference/configuration/)
- See [Real-world Examples](/examples/ecommerce/)
- Read [Best Practices](/explanation/why-discovery/)

View File

@ -0,0 +1,11 @@
---
title: Example Guide
description: A guide in my new Starlight docs site.
---
Guides lead a user through a specific task they want to accomplish, often with a sequence of steps.
Writing a good guide requires thinking about what your users are trying to do.
## Further reading
- Read [about how-to guides](https://diataxis.fr/how-to-guides/) in the Diátaxis framework

View File

@ -0,0 +1,31 @@
---
title: ActivityPub Integration
description: Connect with the Fediverse via WebFinger
---
Set up ActivityPub integration to make your site discoverable on Mastodon and the Fediverse.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Add Team Members
description: Add team member information to humans.txt
---
Learn how to add team members and collaborators to your humans.txt file.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Block Specific Bots
description: How to block unwanted bots from crawling your site
---
Learn how to block specific bots or user agents from accessing your site.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Set Cache Headers
description: Configure HTTP caching for discovery files
---
Optimize cache headers for discovery files to balance freshness and performance.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Use with Content Collections
description: Integrate with Astro content collections
---
Automatically generate discovery content from your Astro content collections.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Custom Templates
description: Create custom templates for discovery files
---
Override default templates to fully customize the output of discovery files.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Customize LLM Instructions
description: Provide specific instructions for AI assistants
---
Create custom instructions for AI assistants to follow when helping users with your site.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Environment-specific Configuration
description: Use different configs for dev and production
---
Configure different settings for development and production environments.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Filter Sitemap Pages
description: Control which pages appear in your sitemap
---
Configure filtering to control which pages are included in your sitemap.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,118 @@
---
title: Welcome to @astrojs/discovery
description: Complete discovery integration for Astro - handles robots.txt, llms.txt, humans.txt, security.txt, canary.txt, webfinger, and sitemap generation
template: splash
hero:
tagline: Make your Astro site discoverable by search engines, AI assistants, humans, and federated services.
actions:
- text: Get Started
link: /getting-started/installation/
icon: right-arrow
variant: primary
- text: View on GitHub
link: https://github.com/withastro/astro-discovery
icon: external
variant: minimal
---
import { Card, CardGrid } from '@astrojs/starlight/components';
## What is @astrojs/discovery?
@astrojs/discovery is a comprehensive Astro integration that automatically generates all standard discovery files for your website. With a single integration, you get complete coverage for search engines, AI assistants, security researchers, and federated services.
## Features
<CardGrid stagger>
<Card title="🤖 robots.txt" icon="rocket">
Dynamic generation with smart defaults and LLM bot support
</Card>
<Card title="🧠 llms.txt" icon="star">
AI assistant discovery and site-specific instructions
</Card>
<Card title="👥 humans.txt" icon="open-book">
Human-readable credits and tech stack information
</Card>
<Card title="🔒 security.txt" icon="approve-check">
RFC 9116 compliant security contact information
</Card>
<Card title="🐦 canary.txt" icon="information">
Warrant canary for transparency and trust
</Card>
<Card title="🔍 WebFinger" icon="magnifier">
RFC 7033 resource discovery (ActivityPub, OpenID)
</Card>
<Card title="🗺️ sitemap.xml" icon="seti:folder">
Automatic sitemap generation with @astrojs/sitemap
</Card>
<Card title="⚡ Zero Config" icon="setting">
Works out of the box with sensible defaults
</Card>
</CardGrid>
## Quick Example
```typescript
// astro.config.mjs
import { defineConfig } from 'astro';
import discovery from '@astrojs/discovery';
export default defineConfig({
site: 'https://example.com',
integrations: [
discovery({
// Optional: customize as needed
llms: {
description: 'Your site description for AI assistants',
},
humans: {
team: [{ name: 'Your Name', role: 'Developer' }],
},
})
]
});
```
That's it! You now have:
- `/robots.txt`
- `/llms.txt`
- `/humans.txt`
- `/sitemap-index.xml`
## Why Use Discovery Files?
Discovery files are essential for modern websites:
- **SEO**: Help search engines understand and index your content correctly
- **AI Integration**: Enable AI assistants to provide better, context-aware help
- **Security**: Provide clear security contact information (RFC 9116)
- **Transparency**: Build trust with warrant canaries
- **Federation**: Connect with decentralized social networks and identity systems
- **Human Touch**: Credit your team and share your story
## Next Steps
<CardGrid stagger>
<Card title="Installation" icon="add-document">
Install @astrojs/discovery in your project
</Card>
<Card title="Quick Start" icon="rocket">
Get up and running in 5 minutes
</Card>
<Card title="Configuration" icon="setting">
Explore all configuration options
</Card>
<Card title="Examples" icon="open-book">
See real-world examples
</Card>
</CardGrid>
## Community
- **GitHub**: [Report issues or contribute](https://github.com/withastro/astro-discovery)
- **Discord**: Join the Astro community
- **Contributing**: Read our contribution guide
## License
MIT Licensed. Built with love by the Astro community.

View File

@ -0,0 +1,31 @@
---
title: API Reference
description: API and programmatic interface reference
---
Complete API reference for programmatic usage of @astrojs/discovery.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Cache Options
description: HTTP caching configuration reference
---
Configure cache control headers for all discovery files.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: canary.txt Options
description: Configuration reference for canary.txt
---
Complete reference for warrant canary configuration options.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Configuration Options
description: Complete reference for all configuration options
---
Comprehensive reference documentation for all available configuration options.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,11 @@
---
title: Example Reference
description: A reference page in my new Starlight docs site.
---
Reference pages are ideal for outlining how things work in terse and clear terms.
Less concerned with telling a story or addressing a specific use case, they should give a comprehensive outline of what you're documenting.
## Further reading
- Read [about reference](https://diataxis.fr/reference/) in the Diátaxis framework

View File

@ -0,0 +1,31 @@
---
title: humans.txt Options
description: Configuration reference for humans.txt
---
Full reference for humans.txt configuration and formatting options.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: llms.txt Options
description: Configuration reference for llms.txt
---
Complete reference for llms.txt configuration options and structure.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: robots.txt Options
description: Configuration reference for robots.txt
---
Detailed reference for all robots.txt configuration options and behaviors.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: security.txt Options
description: Configuration reference for security.txt (RFC 9116)
---
RFC 9116 compliant security.txt configuration reference.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Sitemap Options
description: Configuration reference for sitemap generation
---
Reference for sitemap configuration options (passed to @astrojs/sitemap).
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: TypeScript Types
description: TypeScript type definitions and interfaces
---
Complete TypeScript type reference for configuration and APIs.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: WebFinger Options
description: Configuration reference for WebFinger (RFC 7033)
---
RFC 7033 compliant WebFinger configuration reference.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Basic Setup
description: Set up @astrojs/discovery with default configuration
---
Learn how to set up @astrojs/discovery with the default configuration for immediate use.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Configure robots.txt
description: Customize your robots.txt file
---
Learn how to configure robots.txt to control search engine and bot crawling behavior.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Create humans.txt
description: Add team credits and tech stack information
---
Learn how to create a humans.txt file to credit your team and document your tech stack.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Security & Canary Files
description: Set up security.txt and canary.txt
---
Configure security contact information and warrant canaries for transparency.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: Setup llms.txt
description: Configure AI assistant discovery and instructions
---
Set up llms.txt to help AI assistants understand and interact with your site.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,31 @@
---
title: WebFinger Discovery
description: Enable WebFinger resource discovery
---
Set up WebFinger for ActivityPub, OpenID Connect, and other federated protocols.
:::note[Work in Progress]
This page is currently being developed. Check back soon for complete documentation.
:::
## Coming Soon
This section will include:
- Detailed explanations
- Code examples
- Best practices
- Common patterns
- Troubleshooting tips
## Related Pages
- [Configuration Reference](/reference/configuration/)
- [API Reference](/reference/api/)
- [Examples](/examples/ecommerce/)
## Need Help?
- Check our [FAQ](/community/faq/)
- Visit [Troubleshooting](/community/troubleshooting/)
- Open an issue on [GitHub](https://github.com/withastro/astro-discovery/issues)

View File

@ -0,0 +1,68 @@
/* Custom styles for @astrojs/discovery documentation */
:root {
--sl-color-accent-low: #1e3a8a;
--sl-color-accent: #3b82f6;
--sl-color-accent-high: #60a5fa;
--sl-color-white: #ffffff;
--sl-color-gray-1: #f8fafc;
--sl-color-gray-2: #f1f5f9;
--sl-color-gray-3: #e2e8f0;
--sl-color-gray-4: #cbd5e1;
--sl-color-gray-5: #94a3b8;
--sl-color-gray-6: #64748b;
--sl-color-black: #0f172a;
}
/* Dark mode adjustments */
:root[data-theme='dark'] {
--sl-color-accent-low: #1e3a8a;
--sl-color-accent: #60a5fa;
--sl-color-accent-high: #93c5fd;
--sl-color-white: #0f172a;
--sl-color-gray-1: #1e293b;
--sl-color-gray-2: #334155;
--sl-color-gray-3: #475569;
--sl-color-gray-4: #64748b;
--sl-color-gray-5: #94a3b8;
--sl-color-gray-6: #cbd5e1;
--sl-color-black: #f8fafc;
}
/* Code block enhancements */
.expressive-code {
margin: 1.5rem 0;
border-radius: 0.5rem;
overflow: hidden;
}
/* Callout styling */
.starlight-aside {
border-radius: 0.5rem;
padding: 1rem 1.25rem;
}
/* Enhanced card styling */
.sl-card-grid {
gap: 1rem;
}
/* Table of contents styling */
.right-sidebar {
border-left: 1px solid var(--sl-color-gray-3);
}
/* Better link hover states */
a:hover {
text-decoration: underline;
text-decoration-thickness: 2px;
text-decoration-color: var(--sl-color-accent);
}
/* Page header styling */
.content-panel h1 {
background: linear-gradient(135deg, var(--sl-color-accent) 0%, var(--sl-color-accent-high) 100%);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}

5
docs/tsconfig.json Normal file
View File

@ -0,0 +1,5 @@
{
"extends": "astro/tsconfigs/strict",
"include": [".astro/types.d.ts", "**/*"],
"exclude": ["dist"]
}