GithubHelp home page GithubHelp logo

Implement HTML standard timer APIs about jstime HOT 5 OPEN

jstime avatar jstime commented on June 18, 2024
Implement HTML standard timer APIs

from jstime.

Comments (5)

bengl avatar bengl commented on June 18, 2024 1

Regardless of API, this would still be likely blocked by #12.

from jstime.

devsnek avatar devsnek commented on June 18, 2024

Can we do a promise version instead?

from jstime.

MylesBorins avatar MylesBorins commented on June 18, 2024

@devsnek we could, although I will admit I fail to see value in creating a new timer API that is specific to JSTime. might be worth discussing with HTML + maybe node (deno?) if other platforms would be interested in a promise based API as well

from jstime.

bartlomieju avatar bartlomieju commented on June 18, 2024

Definitely interesting that the JavaScript runtime extensions are implemented in deno_cli not deno_core

As pointed by @bengl timers require event loop. deno_core is agnostic of event loop used and thus timer are implemented in deno_cli (and are built on top of Tokio). The whole timers code is quite complex at the moment because Tokio doesn't support ordered timers (tokio-rs/tokio#1775)

FYI - we'll be moving those APIs to a separate crate in near(-ish) future.

from jstime.

devsnek avatar devsnek commented on June 18, 2024

for timers I would expect a thread with a timer wheel anyway, so not a huge issue for tokio to not be involved.

from jstime.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.