1.0.3 • Published 5 years ago

busy-wait-cursor v1.0.3

Weekly downloads
3
License
ISC
Repository
github
Last release
5 years ago

BUSY-WAIT-CURSOR

Display wait cursor and disable user interaction when broswer is busy

Install

npm i busy-wait-cursor

Usage

import Busy from "busy-wait-cursor";

Busy.wait().then(done => {
  // do something
  done();
});

// or
(async () => {
  await Busy.wait();
  await new Promise(resolve => {
    setTimeout(function() {
      resolve("done");
    }, 5000);
  });
  Busy.done();
})();

Known Issues

Cursor won't change if dev tools is open

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago