We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7e031f5 commit 9d4e44cCopy full SHA for 9d4e44c
src/heapsort.js src/dary.jssrc/heapsort.js renamed to src/dary.js
@@ -4,7 +4,7 @@
4
*
5
*/
6
7
-export function dary(arity) {
+const dary = (arity) => {
8
/**
9
* Note that here we reverse the order of the
10
* comparison operator since when we extract
@@ -13,7 +13,7 @@ export function dary(arity) {
13
* and then pop elements from it until it is empty.
14
15
16
- const sort = function (compare, a, i, j) {
+ const sort = (compare, a, i, j) => {
17
// Construct the max-heap
18
19
let k = i + 1;
@@ -109,4 +109,6 @@ export function dary(arity) {
109
};
110
111
return sort;
112
-}
+};
113
+
114
+export default dary;
src/index.js
@@ -1 +1 @@
1
-export * from './heapsort.js';
+export {default as dary} from './dary.js';
0 commit comments