2020nodesnippets

1.0.6 • Public • Published

2020 Node Snippets

These are some small helpful function for Node.js

Features

  • Easier printing to console
  • Array sorting
  • Array random shuffling
  • Remove item from array by value
  • Remove item from array by index
  • Factorial
  • Permutaion
  • Combination

Installation

To install 2020 Node Snippets, you will need Node.js (https://nodejs.org) and you will need to initialize npm in a directory using npm init. Run the command npm install 2020nodesnippets to install the package in the directory.

Usage Example

const ns = require('2020nodesnippets');
let x = [1, 2, 3, 4, 5];
let y = ns.randshuffle(x);
ns.print(y);

Github Repository and npm package

The Github repository is accessible at https://github.com/NavSous/Node_Snippets The npm package is accessible at https://www.npmjs.com/package/2020nodesnippets

Readme

Keywords

none

Package Sidebar

Install

npm i 2020nodesnippets

Weekly Downloads

8

Version

1.0.6

License

ISC

Unpacked Size

3.32 kB

Total Files

3

Last publish

Collaborators

  • navsous