Add Copilot-specific instructions documenting project overview, tech stack, structure, development guidelines, and best practices for AI-assisted development.
2.1 KiB
2.1 KiB
Copilot Instructions for n-daisuke897-blog
Project Overview
This is a personal blog named "Naputo" built with Astro and Preact. The blog is designed to publish articles and content with a modern static site generation approach.
Repository: https://git.n-daisuke897.com/nakada0907/n-daisuke897-blog
Tech Stack
- Framework: Astro 5.x
- UI Library: Preact 10.x for interactive components
- Language: TypeScript
- Build Tool: Astro CLI
- RSS: @astrojs/rss for RSS feed generation
- Linting: ESLint with TypeScript and Astro plugins
Project Structure
src/: Source codepages/: Astro pages (routing based on file structure)layouts/: Layout componentscomponents/: Reusable componentsblog/: Blog contentstyles/: Global stylesscripts/: Utility scriptscontent.config.ts: Content collection configuration
public/: Static assets (images, fonts, etc.)dist/: Build output directorybuildspec.yml: AWS CodeBuild configuration
Development Guidelines
Commands
npm install: Install dependenciesnpm run dev: Start local development server atlocalhost:4321npm run build: Build production site to./dist/npm run preview: Preview production build locallynpm run astro: Run Astro CLI commands
Coding Standards
- Use TypeScript for all new code
- Follow the ESLint configuration provided
- Use Preact components for interactive UI elements
- Keep components modular and reusable
- Use Astro's component syntax for static content
File Naming
- Use kebab-case for file names
- Use PascalCase for component names
- Use
.astroextension for Astro components - Use
.tsxextension for Preact components
Best Practices
- Prefer static generation over client-side rendering when possible
- Use Astro's content collections for blog posts
- Optimize images and assets before adding to
public/ - Keep bundle size minimal - Astro ships zero JS by default
- Use Preact only when client interactivity is needed
Deployment
This project uses AWS CodeBuild for deployment (see buildspec.yml).