$render stopped working at angular 1.2.2 (file validation directive)

后端 未结 2 798
灰色年华
灰色年华 2021-01-12 18:53

I have migrated from angular 1.0.8 to angular 1.2.2 yesterday, and beside a bunch of other things that got broken and I\'ve already fixed, the $render function on the follow

2条回答
  •  难免孤独
    2021-01-12 19:22

    Increase the priority of your directive to something above 0.

    For example:

    myApp.directive('validFile', function ($filter) {
       return {
         priority: 10,
    

    Here's a detailed explanation of the problem that I found associated with this ui-tinymce issue that's, at it's root, the same as yours.

    The short version of the explanation being that this change causes input's $render to take precedence over your own. By bumping the priority of your directive you, in effect, give your $render priority- as it was before that change in 1.2 rc3.

提交回复
热议问题