Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Average Rating Library

@batya__002/average-rating is a simple JavaScript library that extends the array prototype to calculate the average rating of numerical values.

Table of Contents

Installation

You can install the package using either npm or yarn:

# Using npm
npm i @batya__002/average-rating

# Using yarn
yarn add @batya__002/average-rating

Usage

You can use the

import "@batya__002/average-rating'

Examples

const arr = [20,30,50,"100", true, {id:1}]

console.log(arr.averageRating()); // 50.25
console.log(arr.averageRating(true)); // 50

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages