New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@monaco-editor/react

Package Overview
Dependencies
Maintainers
1
Versions
102
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@monaco-editor/react - npm Package Compare versions

Comparing version 3.4.1 to 3.4.2

5

CHANGELOG.md
### Versions
## 3.4.2
###### *July 15, 2020*
- controlled editor: fix undo/redo issue
## 3.4.1

@@ -4,0 +9,0 @@ ###### *July 3, 2020*

8

lib/ControlledEditor/ControlledEditor.js

@@ -35,3 +35,3 @@ "use strict";

if (currentValue !== previousValue.current && !(ev.isUndoing || ev.isRedoing)) {
if (currentValue !== previousValue.current) {
previousValue.current = currentValue;

@@ -41,6 +41,4 @@

if (typeof _value === 'string') {
if (currentValue !== _value) {
editor.setValue(_value);
}
if (typeof _value === 'string' && currentValue !== _value) {
editor.setValue(_value);
}

@@ -47,0 +45,0 @@ }

@@ -79,13 +79,15 @@ "use strict";

} else {
editorRef.current.executeEdits('', [{
range: editorRef.current.getModel().getFullModelRange(),
text: value
}]);
if (value !== editorRef.current.getValue()) {
editorRef.current.executeEdits('', [{
range: editorRef.current.getModel().getFullModelRange(),
text: value
}]);
if (_isControlledMode) {
var model = editorRef.current.getModel();
model.forceTokenization(model.getLineCount());
if (_isControlledMode) {
var model = editorRef.current.getModel();
model.forceTokenization(model.getLineCount());
}
editorRef.current.pushUndoStop();
}
editorRef.current.pushUndoStop();
}

@@ -92,0 +94,0 @@ }, [value], isEditorReady);

{
"name": "@monaco-editor/react",
"version": "3.4.1",
"version": "3.4.2",
"description": "Monaco editor wrapper for easy/one-line integration with React applications (e.g. powered by create-react-app) without need of webpack configuration files",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc