Skip to content
This repository has been archived by the owner on Jan 25, 2019. It is now read-only.

Latest commit

 

History

History
49 lines (44 loc) · 2.05 KB

README.md

File metadata and controls

49 lines (44 loc) · 2.05 KB

About

Arigato.JS is a Node.js library which provides many utility functions that can be used in various ways

  • Random string, number and float generation
  • String modification
  • String hashing
  • Array utility

Installation

It's recommended to use Node.js v8.0.0 or newer

$ npm i arigato.js    # Using NPM
$ yarn add arigato.js # Using yarn

Example usage

Chunking an Array into parts

const { array } = require( 'arigato.js' );     // Define arigato.js
const characters = [ 'a', 'b', 'c', 1, 2, 3 ]; // Define the array
const chunked = array.chunk( characters, 2 );  // Chunk up the array with 2 entries per chunk
console.log( chunked );						   // [ [ 'a', 'b' ], [ 'c', 1 ], [ 2, 3 ] ] 

Scrambling a string

const { random } = require( 'argiato.js' ); 				// Define arigato.js
const scrambled = random.scramble( 'scrambled'.split('') ); // Scramble the string
console.log( scrambled ); 								    // cadsrelbm ( This may be diffrent for you ) 

Requests

If you have any ideas that you would like to see in arigato.js, you can request them here or here