You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Steps or JS usage snippet reproducing the issue:
Using this on angular 7
import * as monaco from 'monaco-editor';
this._editor = monaco.editor.create(this.editorContainer.nativeElement, {
value: 'function hello() {\n\talert("Hello world!");\n}',
language: 'javascript'
});
When rendering it im getting the follow stack trace:
core.js:15714 ERROR Error: Uncaught (in promise): TypeError: this.model.onDidChangeRawContentFast is not a function
TypeError: this.model.onDidChangeRawContentFast is not a function
at ViewModel.push../node_modules/monaco-editor/esm/vs/editor/common/viewModel/viewModelImpl.js.ViewModel._registerModelEvents (viewModelImpl.js:141)
at new ViewModel (viewModelImpl.js:68)
at StandaloneEditor.push../node_modules/monaco-editor/esm/vs/editor/browser/widget/codeEditorWidget.js.CodeEditorWidget._attachModel (codeEditorWidget.js:939)
at StandaloneEditor.push../node_modules/monaco-editor/esm/vs/editor/standalone/browser/standaloneCodeEditor.js.StandaloneEditor._attachModel (standaloneCodeEditor.js:198)
at new StandaloneEditor (standaloneCodeEditor.js:180)
at standaloneEditor.js:57
at withAllStandaloneServices (standaloneEditor.js:44)
at Object.create (standaloneEditor.js:56)
at MonacoComponent.<anonymous> (main.js:257238)
at step (tslib.es6.js:97)
at resolvePromise (zone.js:831)
at new ZoneAwarePromise (zone.js:913)
at Module.__awaiter (tslib.es6.js:67)
at MonacoComponent.push../Source/app/shared/components/monaco/monaco.component.ts.MonacoComponent._createEditor (main.js:257221)
at MonacoComponent.push../Source/app/shared/components/monaco/monaco.component.ts.MonacoComponent.ngAfterViewInit (main.js:257168)
at callProviderLifecycles (core.js:22406)
at callElementProvidersLifecycles (core.js:22380)
at callLifecycleHooksChildrenFirst (core.js:22370)
at checkAndUpdateView (core.js:23306)
at callViewAction (core.js:23538)
The text was updated successfully, but these errors were encountered:
This can happen only if an editor is created with a model option which is not an instance of a TextModel (aka monaco.editor.createModel). It therefore would not have defined the property onDidChangeRawContentFast
monaco-editor version: 0.16.0
Browser: Chrome
OS:
Steps or JS usage snippet reproducing the issue:
Using this on angular 7
When rendering it im getting the follow stack trace:
The text was updated successfully, but these errors were encountered: