UNPKG
repture
Version:
latest (1.0.0)
1.0.0
Lightweight JavaScript ES6 based utility library
github.com/theahmadzai/repture
theahmadzai/repture
repture
/
src
/
array
/
head.ts
4 lines
(3 loc)
•
117 B
text/typescript
View Raw
1
2
3
4
export
default
function
head
(
array
: Array<any>
)
{
return
(
array
!=
null
&&
array
.length) ?
array
[
0
] : undefined; }