Support for Multi-Domain Locale Detection in Angular SSR

未關閉
#29,111 5 則留言 6 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

評估

難度
5/5
預估耗時
一週以上
新手友好度
25/100
Issue 類型
功能
描述清晰度
需要釐清
活躍度
停滯
技術堆疊
angular, typescript

研究方向

首先定位 Angular SSR 的 locale 設定以及 request/domain 處理入口;issue 未指定任何檔案或測試。完成標準是 SSR 能夠為 example.com、fr.example.com 和 example.de 選擇適當的 locale,而不依賴基於路徑的 locale 片段,並涵蓋支援的對應關係。

由索引模型根據 Issue 內容生成。

描述

area: @angular/ssr feature
Description

Currently, Angular SSR does not provide built-in functionality to detect the domain in a multi-domain setup and serve the appropriate localized version of the application. This feature would allow Angular SSR to dynamically render pages with the correct locale based on the domain.

Use Case:

  • Applications serving different localized versions (e.g., example.com, fr.example.com, example.de) need SSR to serve the appropriate locale.
  • Example:
    • example.com → English content
    • fr.example.com → French content
    • example.de → German content
Describe the solution you'd like

Allow SSR to use the detected domain to select the corresponding locale configuration. Which simplifies multi-language deployment without relying on path-based locales (e.g., /en, /fr).

Describe alternatives you've considered

No response

主要語言
TypeScript
星號
27k
分支
11.8k
平均合併
16 小時 35 分鐘
30 天內合併 PR
176

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

angular/angular-cli 的其他 Issue

查看 angular/angular-cli 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。