Method Chaining

Learn about method chaining and how it works.


Let’s dive into a fundamental concept of D3.js, method chaining. It is the technique where we connect different methods with a period. When we apply a method on an object, it performs an operation and returns an object on which another method can be called. This process is known as method chaining. We will use method chaining throughout this course.


Let’s look at an example of method chaining to see it in action.

Get hands-on with 1200+ tech skills courses.