Skip to content

Add entry_point build option for script tag injection #289

@akroshg

Description

@akroshg

Problem

The Rust WebUI build path does not embed the entry-point script tag in the protocol. Consumers (C++ host, JS dev-server) must post-process rendered HTML to manually inject the tag before </body>.

Solution

Add an optional \�ntry_point\ field to \BuildOptions. When provided, the parser injects <script type="module" src="./NAME.js"></script>\ as a raw fragment immediately before the \�ody_end\ signal. When \None, behavior is unchanged (backward compatible).

Changes

  • \webui-parser: Add \�ntry_point\ field + inject raw fragment before \�ody_end\
  • \webui\ (build API): Add \�ntry_point: Option\ to \BuildOptions, wire to parser
  • \webui-node: Expose \�ntryPoint\ in \JsBuildOptions\
  • DESIGN.md and docs updated

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions