JSFiddle - React, Tailwind, and code Playground
by Alan Doe
HTML
<script src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.4.5/angular.min.js"></script>
<div ng-app="myApp" ng-controller="c">
<boxie cond="{{grot}}"></boxie>
</div>
JavaScript
var mod = angular.module('myApp',['box']);
mod.controller('c',function($scope){
$scope.grot = 'hek';
});
var box = angular.module('box',[]);
box.directive('boxie',function(){
var obj = {
restrict : 'E',
template : '<div style="width:80px;height:80px;">{{cond}} </div>',
link :function(scope,elem,attr,cont){
console.log(scope);
console.log(elem);
console.log(attr);
console.log(cont);
}
};
return obj;
});