From 47cf4b42f650d643b193e25afd6b2ba5e9e92845 Mon Sep 17 00:00:00 2001 From: Todd Jordan Date: Fri, 19 Aug 2016 01:47:04 -0400 Subject: [PATCH] re-render in willUpdate --- addon/components/dynamic-form.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/addon/components/dynamic-form.js b/addon/components/dynamic-form.js index 7a405de..b225181 100644 --- a/addon/components/dynamic-form.js +++ b/addon/components/dynamic-form.js @@ -30,6 +30,7 @@ const DynamicForm = Ember.Component.extend({ }, _render() { + Ember.Logger.debug('_render'); let renderer = get(this, 'formRenderer'); renderer.render(get(this, 'renderSchema'), this.$()); }, @@ -41,6 +42,7 @@ const DynamicForm = Ember.Component.extend({ didReceiveAttrs() { this._super(...arguments); + Ember.Logger.debug('didReceiveAttrs'); let buildSchema = _.flow([ _.bind(this._initSchema, this), _.bind(this._processData, this), @@ -52,7 +54,9 @@ const DynamicForm = Ember.Component.extend({ set(this, 'renderSchema', buildSchema(get(this, 'schema'))); }, - didUpdateAttrs() { + willUpdate() { + this._super(...arguments); + Ember.Logger.debug('willUpdate'); this._render(); },