UNPKG
@doegis/core
Version:
latest (0.1.0)
0.1.0
DOE GIS API
@doegis/core
/
core
/
SetUtils.js
3 lines
(1 loc)
•
245 B
JavaScript
View Raw
1
2
3
import
{isSome
as
r}
from
"./maybe.js"
;
function
n
(
r,n
){
for
(
const
o
of
r.
entries
())
if
(
n
(o[
0
]))
return
!
0
;
return
!
1
}
function
o
(
n,o
){
const
t=
new
Set
;
return
r
(n)&&n.
forEach
((
r
=>
t.
add
(r))),
r
(o)&&o.
forEach
((
r
=>
t.
add
(r))),t}
export
{n
as
someSet,o
as
union};