atomic-fns 0.4.2 → 0.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -11
- package/dist/collections/deque.d.ts +1 -1
- package/dist/collections/deque.js +6 -8
- package/dist/collections/index.d.ts +207 -105
- package/dist/collections/index.js +179 -436
- package/dist/functools/index.d.ts +4 -4
- package/dist/functools/index.js +1 -1
- package/dist/globals/decimal.d.ts +142 -0
- package/dist/globals/decimal.js +371 -0
- package/dist/globals/index.d.ts +19 -15
- package/dist/globals/index.js +10 -24
- package/dist/i18n/currency.d.ts +24 -0
- package/dist/i18n/currency.js +85 -0
- package/dist/i18n/date/index.d.ts +9 -9
- package/dist/i18n/date/utils.d.ts +3 -3
- package/dist/i18n/date/utils.js +6 -28
- package/dist/i18n/format.d.ts +2 -2
- package/dist/i18n/format.js +1 -1
- package/dist/i18n/index.d.ts +1 -0
- package/dist/i18n/index.js +1 -0
- package/dist/itertools/index.d.ts +51 -23
- package/dist/itertools/index.js +4 -32
- package/dist/math/index.d.ts +6 -7
- package/dist/math/index.js +3 -1
- package/dist/operators/index.d.ts +2 -2
- package/dist/operators/index.js +0 -6
- package/dist/random/index.d.ts +1 -1
- package/dist/random/index.js +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -47,17 +47,6 @@ uniqueId('user_')
|
|
|
47
47
|
...
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
You could also import any individual module directly from an html page like this:
|
|
51
|
-
|
|
52
|
-
```html
|
|
53
|
-
<script type="module">
|
|
54
|
-
import {
|
|
55
|
-
namedtuple, FrozenSet, SortedSet, SortedMap
|
|
56
|
-
} from 'https://unpkg.com/atomic-fns/collections';
|
|
57
|
-
// your code goes here...
|
|
58
|
-
</script>
|
|
59
|
-
```
|
|
60
|
-
|
|
61
50
|
See the full list of [modules](https://atomic-fns.dev/modules.html).
|
|
62
51
|
|
|
63
52
|
## Data model
|
|
@@ -111,7 +111,7 @@ export declare class Deque<T = any> extends Sequence<T> {
|
|
|
111
111
|
* Creates an iterator of `[index, value]` pairs for all elements in the deque.
|
|
112
112
|
* @returns {Iterator}
|
|
113
113
|
*/
|
|
114
|
-
entries():
|
|
114
|
+
entries(): Iterable<[number, T]> & Iterator<[number, T], any, undefined>;
|
|
115
115
|
[Symbol.iterator](): Iterable<T>;
|
|
116
116
|
inspect(): any;
|
|
117
117
|
}
|
|
@@ -228,17 +228,15 @@ export class Deque extends Sequence {
|
|
|
228
228
|
return IterableIterator(() => {
|
|
229
229
|
if (j >= l)
|
|
230
230
|
return {
|
|
231
|
-
done: true
|
|
231
|
+
done: true,
|
|
232
|
+
value: undefined
|
|
232
233
|
};
|
|
233
234
|
const value = items[i];
|
|
234
235
|
i++;
|
|
235
236
|
j++;
|
|
236
237
|
if (i === c)
|
|
237
238
|
i = 0;
|
|
238
|
-
return {
|
|
239
|
-
value,
|
|
240
|
-
done: false
|
|
241
|
-
};
|
|
239
|
+
return { value };
|
|
242
240
|
});
|
|
243
241
|
}
|
|
244
242
|
/**
|
|
@@ -260,15 +258,15 @@ export class Deque extends Sequence {
|
|
|
260
258
|
return IterableIterator(() => {
|
|
261
259
|
if (j >= l)
|
|
262
260
|
return {
|
|
263
|
-
done: true
|
|
261
|
+
done: true,
|
|
262
|
+
value: undefined
|
|
264
263
|
};
|
|
265
264
|
const value = items[i];
|
|
266
265
|
i++;
|
|
267
266
|
if (i === c)
|
|
268
267
|
i = 0;
|
|
269
268
|
return {
|
|
270
|
-
value: [j++, value]
|
|
271
|
-
done: false
|
|
269
|
+
value: [j++, value]
|
|
272
270
|
};
|
|
273
271
|
});
|
|
274
272
|
}
|