microsoft / microsoft/monaco-editor
ondidicreacteEditor callBack Can't addcommand
Open
Nobody has claimed this yet.
bug
- Dominant language
- JavaScript
- Stars
- 46.8k
- Forks
- 4.1k
- Avg merge
- 17h 58m
- Merged PRs (30d)
- 1
Description
window.monaco.editor.onDidCreateEditor((editor) => {
var commandId = editor.addCommand(monaco.KeyCode.Tab, function () {
// services available in `ctx`
alert('my command is executing!');
}, '');
console.log(88777, commandId);
});
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 with the onDidCreateEditor callback and editor.addCommand call shown in the issue, then check the Monaco Editor API documentation for their expected arguments. Done means the callback registers a Tab command without the reported failure; record the Monaco version and error if the problem cannot be reproduced.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100