Skip to content
This repository was archived by the owner on May 25, 2019. It is now read-only.

Conversation

@jasonreich
Copy link

Adjusted slightly to respect "updateOn" ngModelOption attributes. Previously, if one specified {updateOn: 'blur'}, the model would never update.

The specific changes are;

  1. A modification of `src/ui-codemirror.js' to add the necessary debounce and commit code (follows that in angular's ngmodel directive).
  2. An additional unit test for the {updateOn: 'blur'} case.

@floribon
Copy link

floribon commented Aug 4, 2016

+1 this is really needed, has uiCodemirror development being abandoned?

@boutils
Copy link

boutils commented Oct 25, 2016

Workaround here:

$scope.editorOptions = {
    onLoad: function(editor) {
        editor.on('blur', function() {
            $scope.myModel = editor.getValue();
        })
    }
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants