Skip to content

aleksandar9999a/ex-worker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ExWorker

ExWorker is TypeScript/JavaScript Library for to perform asynchronous tasks.


How to use

  import ExWorker from 'ex-worker';

  const core = new ExWorker({ mode: 'auto' });

  core.push(() => {
    console.debug('It works!');
  })

  core.push({
    fn: () => {
      console.debug('It works!');
    },
    before: () => {},
    after: () => {},
    priority: 10
  })
  • ExWorker execute tasks by priority (tasks with bigger priority are executed first)
  • ExWorker set default priority 0 if you don't set it
  • ExWorker has possibilities for callback functions
  • ExWorker has auto|manual modes. If mode is manual you must call core.start() to process tasks

About

Library which perform asynchronous tasks.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages