<MonacoDiffEditor>
To show differences between two files, you can use <MonacoDiffEditor>
component.
Usage of <MonacoDiffEditor>
is almost the same as <MonacoEditor>
.
Get & Set values
v-model
is for the modified value. Original value is read-only in monaco-editor.
Fallback Content
Children of <MonacoDiffEditor>
will be shown until the editor is loaded.
Props
plaintext
A programming language for colorization, which will override the editor's option options.language
.
Available languages are listed here.
Options passed to the second argument of monaco.editor.create
.
You can also change the options after the editor mounted.
Available options are listed here.
Original value showed in the editor.
The URI that identifies models.
The URI that identifies models.
Events
Emitted with an instance of IStandaloneCodeEditor
when the editor is loaded
Ref
of <MonacoDiffEditor>
You can access to the editor instance by using useTemplateRef
(or ref
) and $editor
.