I am working with angular-chart.js
and it's not visible in my page, I have put the charts in the directive.
Code I used:
<div class="row">
<div class="cold-md-12">
<canvas class="chart chart-line"
chart-data="data"
chart-labels="labels"
chart-series="series"
chart-options="options"
chart-dataset-override="datasetOverride"
chart-click="onClick"
style="display:block;width:500px;height:400px;">
</canvas>
</div>
</div>
Controller:
app.controller('detailsController',['$scope',function($scope){
$scope.labels = ["January", "February", "March", "April", "May", "June", "July"];
$scope.series = ['Series A', 'Series B'];
$scope.data = [
[65, 59, 80, 81, 56, 55, 40],
[28, 48, 40, 19, 86, 27, 90]
];
$scope.datasetOverride = [{ yAxisID: 'y-axis-1' }, { yAxisID: 'y-axis-2' }];
$scope.options = {
scales: {
yAxes: [
{
id: 'y-axis-1',
type: 'linear',
display: true,
position: 'left'
},
{
id: 'y-axis-2',
type: 'linear',
display: true,
position: 'right'
}
]
}
};
}]);
The controller was placed correctly and the developer tools are not showing any error, also I get the element only problem is the visibility of the map.
It works fine with the following,
DEMO