Building charts and data visualization is awesome. D3 provides amazing capabilities in that domain.
I previously explained how to create the various building blocks of a chart, but one thing is lacking: how to make the chart behave properly at all screen resolutions, aka responsive? Starting from where I left off in the previous post, I will explain how to make a chart responsive. Code can be found on GitHub. (more…)
Posted by huguesstefanski on January 23, 2016
this keyword. However, TypeScript has its own way of dealing with
this that makes the interaction trickier. In this article, I will try guiding you to a way of responding to events with TypeScript.
Posted by huguesstefanski on October 25, 2015
In the previous article, we managed to get data displayed on a time-based chart. Though interesting, this chart is a bit monolithic and quite hard to reuse. The chart class is far from respecting the single responsibility principle, as it fetches the data, renders these, manipulates axes, etc. This article will focus on refactoring the code and somehow improve the lookout of the chart.
Posted by huguesstefanski on October 4, 2015
In the previous article, I explained how to configure the build process and convert an Angular 1 controller to TypeScript. This article will continue building from where we left, and explain how to convert a service and a directive.
Posted by huguesstefanski on August 19, 2015
In this post, I will try to set the basics on how to convert an Angular 1 application to TypeScript. Converting applications to TypeScript/ES6 is a first step towards migrating applications to Angular 2.
This post uses my personal opinions and patterns (if I may use that word). I hope you enjoy reading it; feel free to ask me any question you might have.
As I am focusing on converting an app and not building an app from scratch, I will use John Papa‘s HotTowel generator as the basis for this application. I will therefore keep the spirit and structure of the application, the focus being to move the app to TypeScript.
The interest of this generator is that it is well structured and already comprises a well-established build process.
Code for the completed tutorial can be found on GitHub.
If you are here, I guess you are familiar with Angular. I will assume that you know what TypeScript is, but not much more than that. I will also take it that you know what yeoman is and how it works, as well as npm. Finally, some experience with build processes and gulp is advised.
Posted by huguesstefanski on July 22, 2015
Through this series of articles, I will try to get you:
- understanding how D3 works and how easy it can be to create simple things
- seeing an added value in using TypeScript
- creating a basic build process that will help your development
You can find the completed code for this article here.
Updated on 2016-04-12 to use the new D3 types (generics).
Posted by huguesstefanski on June 7, 2015