[RFC] 多端产物 multi targets 能力
Open
Nobody has claimed this yet.
rfc
- Dominant language
- TypeScript
- Stars
- 18.6k
- Forks
- 2.1k
- PR merge metrics
- No merged PRs in 30d
Description
Summary | 概述
用于支持同时开发多端产物的能力
Motivation | 背景
目标:
- 支持同一个命令行构建多端产物
1.1 build 模式下多进程并发构建 - 支持同一个 DevServer 提供多端产物的本地服务
Usage example | 使用示例
原有指定 target 的方式 (默认值是 "web")
icejs start --target=xxx
新的指定 target 的方式
- 通过 cli 指定
icejs start --target=xxx,yyy
- 在 ice.config.mts 中配置
{
targets: ['xxx', 'yyy'], // string[]
}
Detailed design | 方案设计
每一个构建上下文对应一个 Service
MultiService 同时管理多个 service 的相同接口
DevServer attach 到 MultiService 上
Additional context | 额外信息
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the existing icejs start --target handling and the ice.config.mts configuration described in the issue. Then read the Service, MultiService, and DevServer entry points to understand how build and local serving are currently coordinated. Done means one command or configuration can manage multiple targets for concurrent builds and a shared DevServer.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- build-system, cli, developer-experience
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100