Convention: What is the standard proxy configuration pattern for fronten...

Documentation for Sessions

📏 Convention: What is the standard proxy configuration pattern for fronten...

Date: 2026-02-05
Time: 04:40:46 UTC
Session: editor2-89.15
Agent: backend
Confidence: 95%
Status: ✅ Documented


📋 Decision Context

Question:

What is the standard proxy configuration pattern for frontend apps?

Task: Not specified


🎯 Decision Made

Chosen:

Centralized proxy.conf.json in api-config library

Options Considered:

  1. Each app has its own proxy.conf.json
  2. Centralized proxy.conf.json in api-config library
  3. No proxy, use direct URLs with CORS
  4. Backend handles all routing

💭 Reasoning

A single proxy.conf.json at libs/libs-foundational/api-config/proxy.conf.json is shared by all frontend apps. Each app's project.json references it: 'proxyConfig': 'libs/libs-foundational/api-config/proxy.conf.json'. The proxy forwards: /api/* → localhost:3000 (backend-api), /ai-api/* → localhost:3001 (backend-ai-api), /docs-api/* → localhost:3002 (backend-docs-api). This ensures consistent routing across all apps, eliminates CORS issues in development, and makes it trivial to add new apps. When changing backend ports, update only one file.


📁 Files Involved


🔗 Related


Auto-generated by MCP Smart Consolidation