th-sort

Multithread Quicksort

Usage no npm install needed!

<script type="module">
  import thSort from 'https://cdn.skypack.dev/th-sort';
</script>

README

th-sort

Multithread Quicksort

Simple non-blocking quicksort algorythm in other thread.

Example

sandbox where you can sort one array in main thread and in separated thread.

Usage

import thsort from 'th-sort';

(async () => {
    // array is defined somewhere earlier
    const sorted = await tsort(array);
})()

// Or

tsort(array)
    .then((sorted) => {

    })

Installing

npm i --save th-sort