Skip to content

About

Resources

Contributing

Security policy

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

Β 

History

248 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Softwhere.uz

Next.js TypeScript Neon Tailwind CSS Vercel

A modern, multilingual blog platform and portfolio website built with Next.js 16, featuring AI-powered content generation (DeepSeek), internationalization, and project cost estimator.


Table of Contents


🌟 Features

🌍 Multilingual Support

  • 3 Languages: Uzbek (uz), Russian (ru), English (en)
  • Smart Language Switching: Automatic detection and seamless switching via next-intl
  • Locale-aware Routes: /[locale]/blog, /[locale]/estimator, etc.

πŸ€– AI-Powered Content Generation

  • DeepSeek AI: Blog post generation via DeepSeek API
  • Multi-language Generation: Simultaneous post creation in all supported languages
  • Service Pillars: SEO topics organized by category (mobile-app, MVP, AI, web, telegram, CRM, etc.)
  • Source Material: URL or raw text as input for AI generation
  • Cover Images: Optional Unsplash integration for blog covers

πŸ“ Blog System

  • Dynamic Routing: SEO-friendly URLs with slug-based navigation
  • Rich Content: Markdown with syntax highlighting (rehype-highlight, remark-gfm)
  • Related Posts: Cross-language linking via generationGroupId
  • Categories & Tags: Organized by service pillars
  • Reading Time: Automatic calculation

πŸ’° Project Cost Estimator

  • Multi-step Wizard: Project type, tech stack, complexity, pages, features
  • AI-enhanced Estimates: DeepSeek refines formula-based estimates
  • Project Types: Mobile, web, telegram, desktop, other

🎨 Portfolio & UI

  • Responsive Design: Mobile-first with Tailwind CSS
  • Four looks: visitor-pickable themes on shared tokens (src/modules/home/theme)
  • Animations: AOS (Animate On Scroll), React Type Animation
  • Project Showcase: Portfolio slider with App Store / Play Market links

πŸ“Š Performance & SEO

  • Optimized Images: Next.js Image + Sharp
  • SEO Ready: Meta tags, structured data, sitemap, robots.txt
  • Analytics: Vercel Analytics & Speed Insights

πŸš€ Quick Start

Prerequisites

  • Node.js 24 β€” pinned by .nvmrc and package.json engines (24.x); run nvm use first, since Yarn refuses to install or run scripts on any other version
  • Yarn
  • Neon (serverless Postgres) β€” free tier is fine
  • An AI API key for blog generation (Kimi/Moonshot primary, or DeepSeek) β€” optional

Installation

  1. Clone the repository

    git clone https://github.com/KAMRONBEK/softwhere.uz.git
    cd softwhere.uz
  2. Install dependencies

    nvm use        # Node 24 from .nvmrc
    yarn install
  3. Environment setup

    cp env.example .env.local

    Edit .env.local with your values (see Environment Variables).

  4. Set up the database

    Create the blog_posts and leads tables in your Neon database:

    yarn db:push

    drizzle-kit reads .env (via dotenv/config), not .env.local. Put DATABASE_URL in .env for this step β€” or paste drizzle/0000_init.sql into the Neon SQL editor. See docs/database.md.

  5. Run development server

    yarn dev
  6. Open http://localhost:3000


πŸ”‘ Environment Variables

Variable Required Description
DATABASE_URL βœ… Neon (serverless Postgres) connection string
NEXT_PUBLIC_BASE_URL βœ… Base URL for API calls (e.g. http://localhost:3000)
NEXT_PUBLIC_TG_BOT_TOKEN βœ…* Telegram bot for contact form notifications
NEXT_PUBLIC_TG_CHAT_ID βœ…* Telegram chat for contact form notifications
DEEPSEEK_API_KEY ❌ DeepSeek AI for blog generation & estimator
UNSPLASH_ACCESS_KEY ❌ Cover images for AI-generated posts

*Required for contact form

See env.example for setup. Never commit .env.local or real credentials.


πŸ› οΈ Available Scripts

Script Description
yarn dev Start development server (next dev)
yarn build Build for production
yarn start Start production server
yarn lint Run ESLint
yarn lint:fix Fix ESLint errors
yarn format Format code with Prettier
yarn format:check Check formatting
yarn type-check TypeScript type checking
yarn normalize-line-endings Normalize line endings (LF)
yarn env:pull:development Pull Vercel env for development
yarn env:pull:production Pull Vercel env for production

CLI Scripts (run with npx tsx)

Command Description
npx tsx scripts/generate-post.ts [options] Generate blog post(s) and save to Neon Postgres
npx tsx scripts/regenerate-post.ts [flags] Regenerate/repair existing posts in place
npx tsx scripts/audit-posts.ts [flags] Read-only quality audit of published posts

generate-post options:

  • --category <id> β€” Service pillar (e.g. mobile-app-development, random)
  • --customTopic <str> β€” Custom topic (overrides category)
  • --sourceUrl <url> β€” URL to fetch as source material
  • --sourceText <str> β€” Raw text as source (max 5000 chars)
  • --locales <list> β€” Comma-separated (default: en,ru,uz)

Full, current flag lists for every script live in docs/scripts.md; the GitHub Actions that run them are documented in docs/ci-workflows.md.


πŸ—οΈ Project Structure

softwhere.uz/
β”œβ”€β”€ .github/workflows/
β”‚   β”œβ”€β”€ generate-post.yml    # Scheduled generation (06:17 & 18:17 UTC daily)
β”‚   β”œβ”€β”€ regenerate-post.yml  # Manual in-place post regeneration
β”‚   └── audit-posts.yml      # Monthly read-only quality audit
β”œβ”€β”€ public/                  # Static assets
β”œβ”€β”€ scripts/
β”‚   β”œβ”€β”€ generate-post.ts     # CLI blog post generator
β”‚   β”œβ”€β”€ regenerate-post.ts   # Regenerate/repair posts in place
β”‚   β”œβ”€β”€ audit-posts.ts       # Read-only quality audit
β”‚   └── lib/
β”‚       β”œβ”€β”€ similarity.ts    # Duplicate detection
β”‚       └── post-structure.ts
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ app/                 # Next.js routes (logic-thin); may import any layer
β”‚   β”‚   β”œβ”€β”€ [locale]/        # Internationalized routes
β”‚   β”‚   β”‚   β”œβ”€β”€ page.tsx     # Home
β”‚   β”‚   β”‚   β”œβ”€β”€ admin/       # Admin posts UI
β”‚   β”‚   β”‚   β”œβ”€β”€ blog/        # Blog listing & posts
β”‚   β”‚   β”‚   └── estimator/   # Cost estimator
β”‚   β”‚   β”œβ”€β”€ api/             # API route handlers
β”‚   β”‚   β”œβ”€β”€ sitemap.ts
β”‚   β”‚   └── robots.ts
β”‚   β”œβ”€β”€ core/                # Framework/app-agnostic infra (imports: core only)
β”‚   β”‚   β”‚                    #   env, logger, db, i18n, ai, http, auth, constants
β”‚   β”œβ”€β”€ shared/              # Reusable non-domain code (imports: core, shared)
β”‚   β”‚   β”œβ”€β”€ components/      # site/ (page primitives), TelegramChat, …
β”‚   β”‚   β”œβ”€β”€ data/            # projects
β”‚   β”‚   β”œβ”€β”€ types/
β”‚   β”‚   └── utils/           # slug, analytics, send, security, rateLimit
β”‚   β”œβ”€β”€ modules/             # Business capabilities (imports: core, shared, own module)
β”‚   β”‚   β”œβ”€β”€ blog/            # components, api (generator), model, data, context, utils
β”‚   β”‚   β”œβ”€β”€ estimator/       # components, data, utils, constants, types
β”‚   β”‚   └── admin/           # components, utils
β”‚   β”œβ”€β”€ messages/            # next-intl locale bundles (en/ru/uz)
β”‚   └── proxy.ts             # next-intl routing proxy (middleware)
β”œβ”€β”€ eslint.config.mjs        # ESLint flat config + eslint-plugin-boundaries
β”œβ”€β”€ tailwind.config.ts
└── next.config.mjs

Layer import direction (core β†’ shared β†’ modules β†’ app) is enforced by eslint-plugin-boundaries. See docs/architecture.md.

πŸ“š Full documentation index: docs/README.md β€” architecture, blog pipeline, estimator, i18n, API reference, auth, deployment, SEO, MCP, testing, and ADRs.


πŸ”§ Tech Stack

Layer Technologies
Framework Next.js 16 (App Router)
Language TypeScript 5.8
Styling Tailwind CSS
Database Neon Postgres + Drizzle
AI DeepSeek (OpenAI-compatible API)
i18n next-intl
Deployment Vercel

πŸ“‘ API Routes

Endpoint Method Description
/api/blog/posts GET List blog posts
/api/blog/posts/[slug] GET Single post by slug
/api/blog/posts/related GET Related posts by generationGroupId
/api/blog/generate POST Generate blog posts (AI)
/api/contact POST Contact form (Telegram)
/api/estimate POST Project cost estimate
/api/health GET Health check
/api/health/db GET Database health

πŸ€– GitHub Actions

Three workflows automate the blog. Full detail β€” inputs, secrets, and what each commits β€” is in docs/ci-workflows.md.

Generate Blog Post (generate-post.yml)

  • Schedule: Twice daily at 06:17 and 18:17 UTC
  • Manual: workflow_dispatch with inputs (category, customTopic, sourceUrl, sourceText)

Regenerate Blog Posts (regenerate-post.yml)

  • Trigger: Manual only β€” regenerates/repairs existing posts in place

Blog Audit (audit-posts.yml)

  • Schedule: Monthly, on the 1st at 07:07 UTC β€” read-only quality report

🌐 Deployment

Vercel (Recommended)

  1. Connect the GitHub repo to Vercel
  2. Add environment variables in the Vercel dashboard
  3. Deploy on push to main

Manual

yarn build
yarn start

πŸ“± Development

Line Endings

The project uses LF. After cloning:

git config --local core.autocrlf false
yarn normalize-line-endings

Vercel Env

For local development with production-like env:

yarn env:pull:development
yarn dev

🀝 Contributing

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“„ License

This project is private and proprietary. Β© 2026 All rights reserved.

πŸ“ž Contact


Built with ❀️ using Next.js and modern web technologies

About

Resources

Contributing

Security policy

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages