generate a string of any two characters in combination.
Install globally to use anywhere and get CLI a output a desired helix combination.
npm i -g helix-generator
Local installation can be done as follows.
npm i -S helix-generator
Width works best with even numbers.
Global usabe
helix-generator <helix arguments> -w <width> --cycles <number of cycles>
Local Usage
import helixGenerator from 'helix-generator';
helixGenerator(<helix arguments>, <width default=8>, <number of cycles>);
The following CLI input, with helix arguments 🍯 🐞
and two cycles as -c 2
:
$ helix-generator 🍯 🐞 -c 2
will generate the following output:
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞 🍯
🐞
🍯 🐞
🍯 🐞
🍯 🐞
🍯 🐞
Run the following commands to initialize npm and install helix-generator
npm init -y
npm i -S helix-generator
Then create an index.js
file with the following line.
const generator = require('helix-generator');
console.log(generator(['🤡', '👿', '🤘🏽'], 4, 2));
This will yeild the following output.
🤡 👿 🤘🏽
🤡 👿🤘🏽
🤡 🤘🏽👿
🤡🤘🏽 👿
🤘🏽 🤡 👿
🤘🏽 🤡
🤘🏽 👿 🤡
🤘🏽 👿 🤡
🤘🏽 👿 🤡
👿🤘🏽 🤡
👿 🤘🏽🤡
👿 🤡 🤘🏽
👿 🤘🏽
🤡 👿 🤘🏽
🤡 👿 🤘🏽
🤡 👿🤘🏽
🤡 🤘🏽👿
🤡🤘🏽 👿
🤘🏽 🤡 👿
🤘🏽 🤡
🤘🏽 👿 🤡
🤘🏽 👿 🤡
🤘🏽 👿 🤡
👿🤘🏽 🤡
👿 🤘🏽🤡
👿 🤡 🤘🏽
👿 🤘🏽
🤡 👿 🤘🏽
- [ ] output to file
- [ ] error messages
- [x] implement as npm package
- [x] dynamically changing template for 3+ symbols
- [x] extendable number of symbols