1.0.1 • Published 4 years ago

joinvariant v1.0.1

Weekly downloads
-
License
ISC
Repository
-
Last release
4 years ago

Installation

Install this package

npm install join-variant
const Variant=require(join-variant);

Usage

if you have 2 and up array of variant like this let variant1 = 'red', 'blue', 'white', 'orrange'; let variant2 = 'XL', 'L', 'S', 'XXL'; using

Variant.join(variant1,variant2);

to have

[
[ 'red', 'XL' ], [ 'red', 'L' ],
[ 'red', 'S' ], [ 'red', 'XXL' ],
[ 'blue', 'XL' ], [ 'blue', 'L' ],
[ 'blue', 'S' ], [ 'blue', 'XXL' ],
[ 'white', 'XL' ], [ 'white', 'L' ],
[ 'white', 'S' ], [ 'white', 'XXL' ],
[ 'orrange', 'XL' ], [ 'orrange', 'L' ],
[ 'orrange', 'S' ], [ 'orrange', 'XXL' ]
]
1.0.1

4 years ago