Feedback and criticism wanted: DOMCrypt API proposal

Brendan Eich brendan at
Mon Jun 6 13:00:41 PDT 2011

On Jun 6, 2011, at 9:51 AM, David Dahl wrote:

> On 6/6/11 at 11:00,frantz at (Bill Frantz) wrote:
>> On 6/1/11 at 16:01, ddahl at (David Dahl) wrote:
>>> The property is namespaced in order to provide future capabilities. The current design is asynchronous and looks like this:
>> Is an asynchronous interface the best choice. I thought one of  the great reliability advantages of Javascript was its single-thread, synchronous nature.
> Browsers almost by default will frown on including any synchronous APIs. With Firefox, we just don't want any additional main thread I/O happening.

To say more: JS is single-threaded, but that means you can lock up a "main thread" and starve UI. Browsers use multiple threads and processes these days, but the rule still applies. Scripts run to completion and must pass continuations manually by callback functions if they need to run after some indefinite delay, or even after a just-too-long computation or local i/o operation.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the es-discuss mailing list