I'm trying to make a demo application for integrating d3 with angularjs , I implemented a method defined on ng-newsletter
Project Structure:

main app.js
'use strict';
angular.module('angularD3',['angularD3.controllers','angularD3.directives']);
angular.module('d3Service',[]);
angular.module('angularD3.controllers', []);
angular.module('angularD3.directives', ['d3Service']);
index.html
<!doctype html>
<html ng-app="angularD3">
<head>
<meta charset="utf-8">
<title>d3 and Angular</title>
<meta name="description" content="d3 and Angular">
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css">
<script type="text/javascript" src="scripts/angular.js"></script>
<script src="scripts/app.js"></script>
<script src="scripts/controllers/d3Controller.js"></script>
</head>
<body >
<div ng-controller="DemoCtrl">
{{title}}
<button ng-click="d3OnClick();" name="click button">click button</button>
<d3-bars data="data" ng-model="data[1].score" label="title"></d3-bars>
</div>
</body>
</html>
Controller.js
'use strict';
angular.module('angularD3.controllers').controller('DemoCtrl', ['$scope', function($scope){
$scope.title = "DemoCtrl";
$scope.data = [
{name: "Greg", score:98},
{name: "Ari", score:96},
{name: "Loser", score: 48}
];
$scope.d3OnClick = function(){
alert("item.name");
};
}]);
Other solutions regarding the same problem I was looking at
The problem is that nothing is displayed on the screen, what is the reason?
Please explain the solution code as I am new to angularjs, if you want any other code please ask
What I am missing is also, if you see the code, I commented d3Service.jsin index.html, since it cannot access DemoControllerand is not displayed {{title}}.