Visjs timeline with angularjs template

1.5k views Asked by At

I want to use the Timeline from visjs.org in my AngularJS application. To render the individual cells I want to use an AngularJS template.

On the visjs.org site I can find an example of a Handlebars template, which is working fine.

However I want to use some AngularJS functionality (like i18n filters etc) so I prefer to have a "text/ng-template" template but I don't know how to configure visjs to use AngularJS templates.

Any ideas?

1

There are 1 answers

0
SAMUEL On BEST ANSWER

My primary suggestion to use create a directive or component in new angular version for visjs. or use angular-visjs, a directive module developed by visjs team inoder to support angular projects. But you need to consider the following note from the developers

NOTE: This library is currently being refactored. The intention is make the directives simpler, removing the additional 'non-vis.js' related directives (such as time-board and time-navigation), and bring the DataSet factory in-line with the vis.DataSet such that the documentation for vis is fully (hopefully) applicable and consistent.

                     -The note was taken from ReadMe File on 4 th March 2017

For using template like handlebars you can refer another post from stack overflow itself

Resolve template in AngularJS similar to Handlebars?