code: function highlight(value) {
          var html = ngPrettyJsonFunctions.syntaxHighlight(value) || "";
          html = html
          .replace(/\{/g, "<span class='sep'>{</span>")
          .replace(/\}/g, "<span class='sep'>}</span>")
          .replace(/\[/g, "<span class='sep'>[</span>")
          .replace(/\]/g, "<span class='sep'>]</span>")
          .replace(/\,/g, "<span class='sep'>,</span>");                        
          return isDefined(value) ? scope.tmplElt.find('pre').html(html) : scope.tmplElt.find('pre').empty();
        }
docs: prefer the "json" attribute over the "prettyJson" one. the value on the scope might not be defined yet, so look at the markup.