These are chat archives for AngularClass/angular2-webpack-starter

11th
Jan 2016
David Koch
@thaDude
Jan 11 2016 12:42

Hello,

With some JS libraries I have the issue that I can't use them in my Typescript Angular2 webpack project. I manage to use d3 for instance but cal-heatmapis causing me headaches. npm install cal-heatmap --save; tsd install cal-heatmap --save. In my app code I do: import {CalHeatMap} from 'cal-heatmap'; ... new CalHeatMap(). I pack my app, open in a browser I get a message like TypeError: cal_heatmap_1.CalHeatMap is not a function whenever I do new CalHeatMap();.

This happened to a couple of other libraries as well and I just want to know what the root cause is here and how I can properly debug this kind of error. Any ideas? Thanks.

kamilmowinski
@kamilmowinski
Jan 11 2016 15:03
Hi guys. I have a little question. How can i add new assets, for example static json file?
i always got "Cannot get"
i put my file in src/assets directory and it dont working
ehh my bad
i dont restart server :( sorry guys