Remove default exports (#755)

* Remove default exports

* Cleanup tests

* Exports in util

* Single secp256k1 instance

* Length check

* format check

* encoded lengths
This commit is contained in:
Jaco Greeff
2020-11-08 18:07:31 +01:00
committed by GitHub
parent 80f28da707
commit f07d66562b
238 changed files with 706 additions and 723 deletions
+3 -3
View File
@@ -1,8 +1,8 @@
// Copyright 2017-2020 @polkadot/util authors & contributors
// SPDX-License-Identifier: Apache-2.0
import isNull from '../is/null';
import isUndefined from '../is/undefined';
import { isNull } from '../is/null';
import { isUndefined } from '../is/undefined';
/**
* @name arrayFilter
@@ -20,7 +20,7 @@ import isUndefined from '../is/undefined';
* ```
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
export default function arrayFilter <T = any> (array: T[], allowNulls = true): T[] {
export function arrayFilter <T = any> (array: T[], allowNulls = true): T[] {
return array.filter((value) =>
!isUndefined(value) && (allowNulls || !isNull(value))
);
+1 -1
View File
@@ -5,4 +5,4 @@
* @summary Utility methods that operates on arrays
*/
export { default as arrayFilter } from './filter';
export { arrayFilter } from './filter';