How shtirlizc/tetacom-2022 works
Purpose and runtime
Tetacom is a static Astro marketing/content site for tetacom.pro. Astro renders pages from local components and Markdown content into dist/; browser-side JavaScript is limited to interactive features such as forms and video playback. Primary project entry/configuration points are astro.config.mjs, src/pages/index.astro, and src/layouts/layout.astro.
Page routing and composition
File-based Astro routes define the public site. Static landing pages include home, contacts, model, and education; collection detail pages use dynamic slugs. Shared layouts establish document structure and article presentation, while page files assemble reusable blocks.
Paths: src/pages/products/[slug].astro, src/pages/blog/[slug].astro, src/layouts/article-layout.astro.
Content collections as the CMS boundary
Products, blog posts/cases, news, and vacancies are repository-managed Markdown collections. src/content.config.ts is the schema/collection boundary used by route pages to discover, validate, filter, and render content. Content-associated image folders remain colocated with each article/product.
Paths: src/content.config.ts, src/content/blog, src/content/products.
Content discovery, listing, and taxonomy
Index and tag routes provide collection feeds and category filtering for blog, news, and vacancies. Taxonomy/navigation values are maintained separately from Markdown, creating a distinction between content records and site-level classification/navigation data.
Paths: src/pages/blog/tag/[slug].astro, src/pages/news/tag/[slug].astro, src/data/blog-tags.ts.
Reusable presentation system
src/components supplies the shared shell and UI primitives—header/footer, page metadata, forms, buttons, media, notifications—while src/blocks packages domain/page-section compositions for home, products, news, course, and vacancies. Pages should depend on blocks/components rather than duplicate structural UI.
Paths: src/components/header.astro, src/components/head.astro, src/blocks/home/start-screen.astro.
Client interactions and external services
The feedback flow is client-side: form components/configuration feed src/scripts/form.ts, which uses the public contact endpoint supplied by PUBLIC_TETACOM_CONTACT_ENDPOINT. Cloudflare Turnstile uses PUBLIC_TURNSTILE_SITE_KEY; both values are intentionally bundled at build time. Analytics integration is represented by the Yandex Metrika component. Video behavior is handled separately in the browser.
Paths: src/components/form.astro, src/scripts/form.ts, src/components/yandex-metrika.astro.
Static assets and deployment
Images are bundled from src/assets; directly served PDFs, videos, favicons, verification files, and legal documents live under public. GitHub Actions builds and deploys the generated static output to GitHub Pages, with repository variables supplying public form/Turnstile configuration.
Paths: public/documents, public/video, .github/workflows/deploy.yml.
Main entry points: astro.config.mjs Astro build · header.astro Shared components · blog Markdown collections · content.config.ts Collection schemas
Components 19
Content and taxonomy
- Markdown collections · Products and blog content include colocated images.
src/content/blog - Product content
src/content/products - Collection schemas · Defines and validates repository-managed collections.
src/content.config.ts - Blog tags · Navigation and classification values are separate from Markdown.
src/data/blog-tags.ts
Astro site
- Page routes · File-based routes compose landing, listing, and detail pages.
src/pages/index.astro - Product detail route
src/pages/products/[slug].astro - Blog detail route
src/pages/blog/[slug].astro - Tag listing routes · Filters blog, news, and vacancy feeds by taxonomy.
src/pages/blog/tag/[slug].astro - Article layout · Provides article document structure and presentation.
src/layouts/article-layout.astro - Shared components · Shell, metadata, forms, media, notifications, and buttons.
src/components/header.astro - Page blocks · Reusable domain sections used by pages.
src/blocks/home/start-screen.astro - Astro build · Renders routes, layouts, and content to static output.
astro.config.mjs
Browser integrations
- Feedback form
src/components/form.astro - Form submission · Posts to the public contact endpoint using bundled public settings.
src/scripts/form.ts - Yandex Metrika
src/components/yandex-metrika.astro
Assets and deployment
- Public media and documents · Serves PDFs, videos, favicons, verification, and legal files.
public/documents - Public video
public/video - GitHub Pages deployment · Builds and publishes generated static output.
.github/workflows/deploy.yml - Static output · Deployable Astro build output.
Connections 21
- Collection schemas → Markdown collections: discovers and validates
- Collection schemas → Product content: discovers and validates
- Blog tags → Tag listing routes: drives filters
- Markdown collections → Blog detail route: renders record
- Product content → Product detail route: renders record
- Markdown collections → Tag listing routes: supplies feeds
- Page routes → Page blocks: composes
- Page routes → Shared components: uses
- Product detail route → Article layout: uses
- Blog detail route → Article layout: uses
- Article layout → Shared components: uses
- Feedback form → Form submission: submits through
- Shared components → Feedback form: includes
- Shared components → Yandex Metrika: includes
- Astro build → Page routes: builds
- Astro build → Collection schemas: loads collections
- Astro build → Public media and documents: copies
- Astro build → Public video: copies
- Astro build → Static output: generates
- GitHub Pages deployment → Astro build: runs build
- GitHub Pages deployment → Static output: publishes