The queue.defer() function in d3.js is used to add the asynchronous task callback to the queue. Where the task is a function to be executed. The callback must be executed when the task got finished.
Parameters: This function accepts a single parameter as mentioned above and described below:
- task: It is a function that is to be executed to perform a particular task.
Return Value: This function returns the object.
Below given are a few examples of the above function.
Example 1: When the size of the queue is equal to the number of queue.defer() calls.
Example 2: When the size of the queue is less than the queue.defer() calls.
- How to get the function name inside a function in PHP ?
- PHP | imagecreatetruecolor() Function
- p5.js | year() function
- D3.js | d3.utcTuesdays() Function
- PHP | ImagickDraw getTextAlignment() Function
- PHP | Ds\Sequence last() Function
- Function to escape regex patterns before applied in PHP
- PHP | array_udiff_uassoc() Function
- PHP | geoip_continent_code_by_name() Function
- D3.js | d3.map.set() Function
- D3.js easePolyOut Function
- PHP | GmagickPixel setcolor() function
- PHP | opendir() Function
- PHP | cal_to_jd() Function
- D3.js | d3.bisectLeft() Function
- PHP | stream_get_transports() Function
- PHP | Ds\Deque pop() Function
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.