var myApp = angular.module( 'myApp', [] ); myApp.directive( 'myDirectiveName' , function() { return { restrict:"E", transclude:true, template:'<textarea rows="10" columns="10" ng-transclude ></textarea>' } } );
var myApp = angular.module("myApp", [ ] ); myApp.directive( 'myDirectiveName' , function() { return { restrict:"E", link:function (scope, element, attrs) { var htmlText ="<div>some stuff</div>"; element.html( htmlText ); } } } );