D3.js scaleTime time() Function
The time() function of d3.scaleTime() is used to return a value from and within the given range from the specified domain.
Parameter: This function accepts only one parameter as mentioned above and described below.
- value: This accepts a value from the specified domain.
Return Value: This function returns a value from the range.
Below example illustrates the scaleTime time() function in D3.js: