monaco-editor
Advanced tools
Changelog
[0.8.1] (27.01.2017)
Intl
missing.disableMonospaceOptimizations
editor option that can be used in case browser zooming exposes additional issues.formatOnPaste
editor option.IActionDescriptor.precondition
.registerTypeDefinitionProvider
to registerImplementationProvider
and associated types.Changelog
[0.8.0] (18.01.2017)
monaco-typescript
(JS and TS language support).nextEmbedded
), the state ending up in must immediately contain a nextEmbedded: "@pop"
rule. This helps in quickly figuring out where the embedded mode should be left. The editor will throw an error if the Monarch grammar does not respect this condition.span
node of text, and CSS rules would match token types and assign styling to them (i.e. color, boldness, etc.to style tokens)monaco.editor.defineTheme()
and the playground contains a sample showing how that works.F1
> Developer: Inspect tokens
. This will bring up a widget showing the token type and the applied styles.monaco.editor.onDidCreateEditor
that will be fired whenever an editor is created (will fire even for a diff editor, with the two editors that a diff editor consists of).monaco.editor.tokenize
that returns logical tokens (before theme matching, as opposed to monaco.editor.colorize
).monaco.languages.registerTypeDefinitionProvider
IModel.getMode()
.IModelLanguageChangedEvent
, IModelDecorationsChangedEvent
and IModelTokensChangedEvent
;IModel.findMatches
, IModel.findNextMatch
and IModel.findPreviousMatch
to be able to capture matches while searching.ICodeEditor.addAction
and IDiffEditor.addAction
now return an IDisposable
to be able to remove a previously added action.ICodeEditor.onDidChangeModelMode
to ICodeEditor.onDidChangeModelLanguage
;ICodeEditor.executeEdits
can now take resulting selection for better undo/redo stack management;ICodeEditor.getTargetAtClientPoint(clientX, clientY)
to be able to do hit testing.IViewZone.marginDomNode
to be able to insert a dom node in the margin side of a view zone.lineDecorationsWidth
can now take a value in the form of "1.2ch"
besides the previous accepted number (in px)renderLineHighlight
can now take a value in the set 'none' | 'gutter' | 'line' | 'all'
.fixedOverflowWidgets
to render overflowing content widgets as 'fixed'
(defaults to false)acceptSuggestionOnCommitCharacter
to accept suggestions on provider defined characters (defaults to true)emptySelectionClipboard
- copying without a selection copies the current line (defaults to true)suggestFontSize
- the font size for the suggest widgetsuggestLineHeight
- the line height for the suggest widgetrenderIndicators
- Render +/- indicators for added/deleted changes. (defaults to true)Changelog
[0.7.0] (07.10.2016)
monaco.d.ts
).editor.addAction()
and have the action show in the context menu.lineNumbers
: 'on' | 'off' | 'relative'
renderWhitespace
: 'none' | 'boundary' | 'all'
model.setMode()
, as IMode
will soon disappear from the API.monaco-editor-core
:
monaco-editor-core
is now finally language agnostic.monaco-languages
.monaco-html
.monaco-editor-core
, we could improve the bundling and reduce the number of .js files we ship.Changelog
[0.6.1] (06.09.2016)
editor.addCommand
was no longer working.Changelog
[0.6.0] (05.09.2016)
monaco.d.ts
is generated by TypeScript 1.8.javascript
and typescript
language services:
extraLibs
.css
, less
, scss
and json
language services.mouseWheelZoom
, wordWrap
, snippetSuggestions
, tabCompletion
, wordBasedSuggestions
, renderControlCharacters
, renderLineHighlight
, fontWeight
.tabFocusMode
, outlineMarkers
.indentGuides
-> renderIndentGuides
, referenceInfos
-> codeLens
editor.pushUndoStop()
to explicitly push an undo stopsuppressMouseDown
to IContentWidget
resolveLink
to ILinkProvider
enablement
, contextMenuGroupId
from IActionDescriptor
Changelog
[0.5.0] (24.06.2016)
monaco.editor.createWebWorker
now loads the AMD module and calls create
and passes in as first argument a context of type monaco.worker.IWorkerContext
and as second argument the initData
. This breaking change was needed to allow handling the case of misconfigured web workers (running on a file protocol or the cross-domain case)CodeActionProvider.provideCodeActions
now gets passed in a CodeActionContext
that contains the markers at the relevant range.hoverMessage
of a decoration is now a MarkedString | MarkedString[]
contents
of a Hover
returned by a HoverProvider
is now a MarkedString | MarkedString[]
IEditor.onDidChangeModelRawContent
, IModel.onDidChangeRawContent
file://
or misconfigured cross-domain loading) now load the web worker code in the UI thread. This caused a breaking change in the behaviour of monaco.editor.createWebWorker
position:fixed
element.