promise-dot-lua

A JavaScript-style Promise library for Lua

$ luarocks install promise-dot-lua

A JavaScript-style Promise library for Lua

See https://ezhik.jp/promise.lua for more information and a playground.

I tried to cover most of the API I saw on MDN.

I've kept this async runtime-agnostic. You can override the Promise.schedule(fn) function with your own implementation that will schedule functions for later asynchronous execution. An example implementation for Hammerspoon is provided in the repository.

Versions

1.1.0-18 hours ago3 downloads

Dependencies

lua >= 5.1

Manifests