Skip to content

[Feature] Resolve stable local constant BrowserWindow options through shared binding facts #4366

Closed

Description

@N0zoM1z0

Before submitting

Area

Evidence, artifacts, or reconstruction

Current limitation

At 8ab5024397ddbd3b37ab68a13cabedc2eb7ce7dd, inspectBrowserWindow accepts only inline object syntax. A same-scope const options = {webPreferences: {nodeIntegration: true, contextIsolation: false}}; new BrowserWindow(options) remains dynamic. This is source-derived on current main; #3536 reports earlier executed CLI reproductions and the actual Joplin 3.7.21 ElectronAppWrapper.js case.

Desired outcome and success criteria

Resolve unambiguous same-scope const option/preference object initializers through the existing lexical and alias-aware mutation owner. Preserve shadowing, unknown computed overrides, reassignment, mutation, escape, cycles and use-before-initialization as uncertainty. Preserve exact source Evidence and original constructor identity. Do not execute target code, infer Electron defaults, or add tools. Keep equivalent inline inputs unchanged.

This slice excludes setWindowOpenHandler override records/parent relations; #3536 remains open for that independent contract change.

Expected interaction with targets

Read existing files as inert source.

Verification available so far

Source inspection plus prior public-app report in #3536. Current-runtime reproduction and performance measurements are pending.

Verification details

Use the unchanged official Joplin 3.7.21 ASAR and exact source selection, compare current-main vs candidate CLI/MCP and retained facts, and record token/context, elapsed/CPU and process-family memory costs. Add deterministic negative source cases at the producing boundary. No runtime Electron behavior is claimed by static reconstruction.

Alternatives considered

Manual source reading preserves facts but leaves the shared graph and summary incomplete. A separate resolver duplicating lexical/mutation interpretation would create maintenance and correctness risks.

References

Parent #3536; umbrella #4027; code-mode deferral #4091.

Activity

  1. added
    enhancement
    on Oct 16, 2026
  2. added
    area: evidence
    on Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: evidenceenhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions