Merge pull request #127 from clarkio/patch-1

clarify how to remove decorations for a decoration type from view
This commit is contained in:
Martin Aeschlimann
2019-01-03 07:20:00 +01:00
committed by GitHub

View File

@ -67,4 +67,6 @@ activeEditor.setDecorations(smallNumberDecorationType, smallNumbers);
## Tips
As a note, if you insert a new range of decorations using `editor.setDecorations` with a `TextEditorDecorationType` that has already been used, it will overwrite the previous set of decorations.
As a note, if you insert a new range of decorations using `editor.setDecorations` with a `TextEditorDecorationType` that has already been used, it will overwrite the previous set of decorations.
If you'd like to remove a decoration(s) of a certain decoration type then pass in an empty array to clear it from the editor. Example: `editor.setDecorations(decorationType, []);`