Skip to content

fix: include new source files in runtime package exports#5797

Merged
leaanthony merged 3 commits into
wailsapp:masterfrom
savely-krasovsky:fix-runtime-compilation
Jul 26, 2026
Merged

fix: include new source files in runtime package exports#5797
leaanthony merged 3 commits into
wailsapp:masterfrom
savely-krasovsky:fix-runtime-compilation

Conversation

@savely-krasovsky

@savely-krasovsky savely-krasovsky commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Description

I forgot to include those new files and wails3 build/package broke if you import local runtime with non-client test hit support. This fixes the issue.

Fixes # (issue)

Type of change

Please select the option that is relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration using wails doctor.

  • Windows
  • macOS
  • Linux

If you checked Linux, please specify the distro and version.

Test Configuration

Please paste the output of wails doctor. If you are unable to run this command, please describe your environment in as much detail as possible.

Checklist:

  • (v2 only) I have updated website/src/pages/changelog.mdx with details of this PR (v3 changelog entries are added automatically)
  • My code follows the general coding style of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

Summary by CodeRabbit

  • Bug Fixes
    • Improved runtime packaging behavior to ensure required desktop interaction features are preserved during production builds.

@coderabbitai

coderabbitai Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: cc3d565d-44df-4f07-8133-dafe5abd102b

📥 Commits

Reviewing files that changed from the base of the PR and between 107e42c and 8b2d563.

📒 Files selected for processing (1)
  • v3/internal/runtime/desktop/@wailsio/runtime/package.json

Walkthrough

The runtime package’s sideEffects metadata now includes four source entry modules in addition to the existing distribution entry.

Changes

Runtime metadata

Layer / File(s) Summary
Side-effect entry configuration
v3/internal/runtime/desktop/@wailsio/runtime/package.json
The sideEffects array now includes src/index.ts, src/appregion.ts, src/contextmenu.ts, and src/drag.ts alongside ./dist/drag.js.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested labels: Bug

Suggested reviewers: invalid-email-address

Poem

I’m a rabbit with metadata bright,
Marking source modules just right.
No tree-shaking surprise,
Four entries arise—
And the runtime hops into flight!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description is mostly template text and lacks a specific issue number, testing details, and completed checklist items. Add the linked issue number, summarize the fix with motivation/context, describe tests and environment, and complete the checklist.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title matches the runtime package change, but "exports" is slightly misleading for a sideEffects metadata update.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@leaanthony leaanthony left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct change, though the title undersells and slightly misnames it: this is the sideEffects array, not exports.

Worth being precise about the scope, because it affects who benefits. The published tarball ships files: ["./dist", "./types"], so ./src/*.ts is not in it and consumers of the npm package are unaffected either way. Where it matters is consumption from source: the in-repo examples, and anyone linking the runtime with a file: dependency during development. There a bundler resolving the TypeScript sources can tree-shake the side-effectful modules away, and index.ts registering WML is exactly the kind of thing that must survive. Entries that match no file are ignored, so there is no downside for the published package.

Approving. Metadata-only, no runtime behaviour change for published consumers.

@leaanthony
leaanthony merged commit c5ddfc6 into wailsapp:master Jul 26, 2026
44 checks passed
leaanthony pushed a commit that referenced this pull request Jul 26, 2026
@savely-krasovsky
savely-krasovsky deleted the fix-runtime-compilation branch July 26, 2026 13:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants