Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alexander
bls-score
Commits
3fcf04b1
Commit
3fcf04b1
authored
Jul 02, 2021
by
Alexander Butyaev
Browse files
clean up
parent
d267b676
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/index.ts
View file @
3fcf04b1
...
...
@@ -11,11 +11,11 @@ import {
* @returns score [Number] (positive number rounded up)
*/
function
__calculateScore
(
_
sequences
:
Array
<
string
|
Array
<
string
>>
,
_
guides
:
Array
<
string
>
,
sequences
:
Array
<
string
|
Array
<
string
>>
,
guides
:
Array
<
string
>
,
options
:
any
):
number
{
return
__calculateScoreV1
(
_
sequences
,
_
guides
,
options
);
return
__calculateScoreV1
(
sequences
,
guides
,
options
);
}
/**
...
...
@@ -26,11 +26,11 @@ function __calculateScore(
* @returns score [Number] (positive number rounded up)
*/
function
calculateScore
(
_
sequences
:
Array
<
string
|
Array
<
string
>>
,
sequences
:
Array
<
string
|
Array
<
string
>>
,
guides
:
Array
<
Array
<
string
>>
,
options
:
any
):
number
{
return
calculateScoreV1
(
_
sequences
,
guides
,
options
);
return
calculateScoreV1
(
sequences
,
guides
,
options
);
}
export
{
calculateScore
,
__calculateScore
};
src/v1/index.ts
View file @
3fcf04b1
...
...
@@ -6,14 +6,14 @@
* @returns score [Number] (positive number rounded up)
*/
function
__calculateScore
(
_
sequences
:
Array
<
string
|
Array
<
string
>>
,
sequences
:
Array
<
string
|
Array
<
string
>>
,
_guides
:
Array
<
string
>
,
options
:
any
=
{}
):
number
{
const
guides
:
Array
<
Array
<
string
>>
=
(
_guides
||
[]).
map
((
o
:
string
)
=>
{
return
o
.
split
(
'
:
'
).
filter
((
elm
:
string
)
=>
elm
!==
'
-
'
);
});
return
calculateScore
(
_
sequences
,
guides
,
options
);
return
calculateScore
(
sequences
,
guides
,
options
);
}
/**
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment