ember-forge / ember-forge-ui

Ember.js UI Components that are independent of any specific CSS framework
MIT License
1 stars 2 forks source link

DEPRECATION: ember-views.render-double-modify #152

Closed notmessenger closed 8 years ago

notmessenger commented 8 years ago

DEPRECATION: You modified (-join-classes "ember-view" "ef-textarea" (-normalize-class "errorState" errorState activeClass="ef-error" inactiveClass=undefined)) twice in a single render. This was unreliable in Ember 1.x and will be removed in Ember 3.0 [deprecation id: ember-views.render-double-modify]

This was introduced by https://github.com/ember-forge/ember-forge-ui/commit/1beda3fabf0455ef15bc8cedca13b9134dc07a77 which is the commit that ties the existence of error to error state on associated element. This error comes to be when the data on the errors object is modified. It's because of the

  classNameBindings: [
    'errorState:ef-error'
  ],

binding but I have not yet figured out what exactly is causing it, as the logic that updates the errorState property - updateErrorState() is not being called more than once.

notmessenger commented 8 years ago

https://github.com/ember-forge/ember-forge-ui/commit/d513da0516e4d7c4d3a1f85e33db56f11667c5d3 extracted the previous commit into a mixin.

notmessenger commented 8 years ago

https://github.com/ember-forge/ember-forge-ui-bootstrap4/commit/1a741b667a763464eb2aa2d31d319305df4f7d87 experiences this problem as well.

notmessenger commented 8 years ago

Was resolved by https://github.com/ember-forge/ember-forge-ui/commit/0c44a73d06d434447b82842d1525c8a74369cd36