🚀 DAY 2 OF LAUNCH WEEK: Unify Your Security Stack with Socket Basics.Learn more →
Socket
Book a DemoInstallSign in
Socket

@ilihub/decade

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ilihub/decade

TypeScript functions for converting decade to other time units.

latest
Source
npmnpm
Version
1.0.1
Version published
Weekly downloads
2
-71.43%
Maintainers
1
Weekly downloads
 
Created
Source

@ilihub/decade

TypeScript functions for converting decade to other time units.

NPM Version NPM CodeFactor Socket Badge

Installation

# if you're using pnpm
pnpm add @ilihub/decade

# or, if you're using npm
npm install @ilihub/decade

# or, if you're using yarn
yarn add @ilihub/decade

Usage

import { Decade } from "@ilihub/decade";

const decade = new Decade(1);

const milliseconds = decade.toMillisecond();
console.log(milliseconds); // 315360000000

const seconds = decade.toSecond();
console.log(seconds); // 315360000

const minutes = decade.toMinute();
console.log(minutes); // 5256000

const hours = decade.toHour();
console.log(hours); // 87600

const days = decade.toDay();
console.log(days); // 3650

const weeks = decade.toWeek();
console.log(weeks); // 520

const months = decade.toMonth();
console.log(months); // 120

const years = decade.toYear();
console.log(years); // 10

const centuries = decade.toCentury();
console.log(centuries); // 0.1

Available Functions and Classes

Sponsors & Backers

Support the development of new open-source projects from ilihub through crowdfunding.

The core of ilihub is our crowd-funded open-source projects, licensed under the permissive MIT license. Sponsorship increases the rate of bug fixes, documentation improvements, and feature development.

Sponsors

Keywords

ilihub

FAQs

Package last updated on 01 Nov 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts