var app = angular.module('makeithappen');
app.run(['RenderService', 'PathResolver', '$rootScope', function(RenderService, PathResolver, $rootScope) {

    function PolymerControl() {

        var instance;
        var path;

        // set-up event binding
        document.addEventListener('WebComponentsReady', function() {
            var input = document.querySelector('paper-input');
            input.addEventListener('keyup', function() {
               instance[path] = input.value;
                $rootScope.$digest();
            });
        });

        return {
            priority: 100,
            render: function(element, schema, schemaPath, services) {
                var control = JSONForms.RenderDescriptionFactory.createControlDescription(schemaPath, services, element);
                var data = services.get(JSONForms.ServiceId.DataProvider).getData();
                path = PathResolver.toInstancePath(schemaPath);
                instance = data;
                control['template'] =
                 '<div class="panel panel-default">' +
                    '<paper-input type="text" value="{{element.instance[\'' + path + '\']}}" data-jsonforms-model label="Last name goes here"></paper-input>' +
                 '</div>';
                return control;
            },

            isApplicable: function (element, subSchema, schemaPath) {
                return element.type == "Control" && schemaPath.endsWith("lastName");
            }
        }
    }

    RenderService.register(new PolymerControl());
}]);
@@ -382,16 +382,45 @@
 nput');%0A
+            if (input) %7B%0A    
         
@@ -455,37 +455,43 @@
 keyup', function
+ 
 () %7B%0A
+     
                i
@@ -535,16 +535,20 @@
         
+    
 $rootSco
@@ -557,24 +557,28 @@
 .$digest();%0A
+    
             
@@ -581,16 +581,30 @@
     %7D);%0A
+            %7D%0A
         

Fix polymer example