Questions tagged [timing]

Timing refers to the quantifiable assessment of the duration it takes for an instruction or sequence of instructions to be executed.

Is it possible to determine the duration of a JQuery AJAX call's execution?

Is it possible to measure the duration of a $.getJSON method call using timing code in jQuery/JavaScript? Additionally, is there a method to determine the size of the response Content-Length, measured in kilobytes or megabytes? ...

Minimizing Jitter in HTML5 and JavaScript Applications

I am currently working on developing a metronome as a hobby using JavaScript/HTML5 with the intention of turning it into a FirefoxOS app. One issue I've encountered is Jitter, which is unacceptable for Metronomes. As JavaScript is single-threaded and ...

Struggling to get JQuery timing events to function properly?

Encountering timing issues with the events in my self-made simon memory game. Experimented with setTimeout but struggling to figure out which events to time and the appropriate duration for them to be distinguishable. $('#play').click(function( ...

What is the best way to implement a function in a discord.py command that restricts the use of a command to only once per minute?

What is the best way to ensure a command in discord.py can only be used once every minute? @bot.command() async def busk(ctx): member = ctx.message.author.id #gets the user ID, which i use as the _id in pymongo because everyones is different. ...

Ways to ascertain if a view has completed rendering in JavaScript

I am currently building my application using the awesome backbone.js framework. Within my code, I have this layoutView that handles rendering the overall layout and also includes a smaller profile section. The dilemma I'm facing is with the timing o ...

Timing problem with the getJSON function in jQuery

My program seems to be skipping the result of a JSON call. Is there a way I can implement a closure function here or make the program wait for the JSON call to return? function checkIfUsernameIsDuplicate(username) { var functionName = "get_username"; ...

The timing of setTimeout within the $.each function does not behave as expected

I am looking to back up a list, delete all items within it, and then append each item one by one with a delay of 1 second between them. This is the approach I have taken: var backup = $('#rGallery').html(); $('#rGallery li').remove(); ...

How can you stop queuing animations and timeouts in jQuery?

I'm facing a seemingly simple problem that I need help with. On my website, there's a hidden div.notification bar at the top. This bar can be displayed by adding either the success or warning class to it. There are two scenarios: either a messa ...