npm.io
0.2.11 • Published 5 years ago

@scalecube/utils

Licence
MIT
Version
0.2.11
Deps
1
Size
56 kB
Vulns
0
Weekly
0

Join the chat at https://gitter.im/scalecube-js/Lobby

NOTICE versions 0.0.x are experimental without LTS or the API and behavior might change from patch to patch

Scalecube utils

reusable utils library

address

getFullAddress

Given valid address: Address
When  calling getFullAddress(address)
Then  fullAddress will be added to the address object
validateAddress
Given address: any
And   isOptional: boolean
# isOptional = true
When  calling validateAddress(address, isOptional) 
Then  valid address can be undefined or type Address
# isOptional = false
When  calling validateAddress(address, isOptional) 
Then  valid address must be of type Address