#55312: docs: remove redundant shell requires in application menu tutorial
Merged
Description of Change
In the docs, const { shell } = require('electron') duplicates the top-level const { shell } = require('electron/common').
The inner require('electron') was migrated from docs/api/menu.md, where the top-level import did not include shell, so the local require was necessary there.
This PR keeps the top-level electron/common import and removes the redundant inner require('electron'). The @ts-expect-error line annotations on the two code fences are updated for the shifted line numbers (verified with npm run lint:docs).
Checklist
- I have filled out the PR description
- I have reviewed and verified the changes
- relevant API documentation, tutorials, and examples are updated and follow the documentation style guide
Release Notes
Notes: none
Backports
46-x-y
MergedPR Number
#55364Merged At
Oct 26, 2026, 2:27:44 PM
Released In
v46.0.0-alpha.2Release Date
Oct 26, 2026, 3:00:25 PM
Semver Impact
Major
Breaking changes
Minor
New features
Patch
Bug fixes
None
Docs, tests, etc.
Semantic Versioning helps users understand the impact of updates:
- Major (X.y.z): Breaking changes that may require code modifications
- Minor (x.Y.z): New features that maintain backward compatibility
- Patch (x.y.Z): Bug fixes that don't change the API
- None: Changes that don't affect using facing parts of Electron