Skip to content

Johna-123/get-current-age

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

get-current-age

This package returns the current age depending on the birthdate you input.

Installation

Install the package:

npm install get-current-age

Usage

Import the package to your JavaScript file:

import age from "get-current-age";

Get age:

const day = 30,
      month = 9,
      year = 2007;
       
const myAge = age(day, month, year);

console.log("I am " + myAge + " years old");

Releases

No releases published

Packages

No packages published