Skip to content

[break] feat(scene): publish shared browser runtime and host capabilities - #1007

Open
DecviL wants to merge 8 commits into
cocos:mainfrom
DecviL:fix/browser-scene-runtime
Open

DecviL wants to merge 8 commits into
cocos:mainfrom
DecviL:fix/browser-scene-runtime

Conversation

@DecviL

@DecviL DecviL commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

The scene editor needs to use the same CLI scene services as its host without bundling another copy of the CLI implementation. This change publishes the shared browser runtime, supplies host-owned implementations through capabilities, and generates declaration-only inputs for the extension.

  • Build and serve the shared scene core, EditorExtends, polyfills, loader, and import map through build-specific runtime URLs.
  • Add cocos-cli/scene-editor/host and a browser host adapter with capabilities API 1, preserving the page SystemJS instance during service initialization.
  • Generate self-contained scene editor declarations as part of CLI builds, and expose runtime enum values required by injected modules.
  • Keep browser manifest API 1 and add capabilitiesApiVersion so existing protocol 2 consumers retain their loader contract. Protocol 3 consumers require the corresponding scene editor extension and PinK loader updates.

Validation:

  • npm run compile passed, including browser runtime and declaration generation.
  • Four targeted CLI test suites passed: 22 tests covering browser hosting, resource routes, module maps, and deferred module resolution.
  • The matching scene editor extension built successfully; 58 suites / 687 unit tests and 28 VSIX delivery tests passed against this CLI.
  • PinK client type checking and layer checks passed with the matching loader changes.

Full PinK UI interaction and native simulator regression tests were not run.

@DecviL DecviL changed the title feat(scene): publish shared browser runtime and host capabilities [break] feat(scene): publish shared browser runtime and host capabilities Oct 23, 2026
@DecviL
DecviL requested a review from bofeng-song October 23, 2026 10:47
@DecviL
DecviL changed the base branch from v0.2.0-beta.0 to main October 26, 2026 04:22
@DecviL DecviL closed this Oct 27, 2026
@DecviL DecviL reopened this Oct 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant