microsoft / microsoft/monaco-editor
`ViewImpl` follow the open–closed principle
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 46.8k
- Forks
- 4.1k
- Avg merge
- 17h 58m
- Merged PRs (30d)
- 1
Description
ViewImplis directly depend on viewParts implementation, like:
import { Margin } from 'vs/editor/browser/viewParts/margin/margin';
import { Minimap } from 'vs/editor/browser/viewParts/minimap/minimap';
And keep viewParts private, that make custom Margin, Minimap logic without modify source code impossible.
But for users of this library, it's a natural request that extend the original editor feature by compose/extend the original implementation without touch source code.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading src/vs/editor/browser/view/viewImpl.ts and the imported viewParts implementations, including Margin and Minimap. Trace how ViewImpl owns and constructs these parts, then review the surrounding editor view APIs. Done should be a decided extensibility design that allows custom view-part behavior without modifying the source implementation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100