npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

fncrsv

v1.4.2

Published

function Reservator for Node.js

Downloads

8

Readme

Function Reservator: Function administration module

TL:DR

  • This project is developed by nate.crema
  • If error, please report issuse to github!
  • This module's parameter type is change due to 'timeType' option. PLZ check function introduction

Index

Introduction

Function-administration module.

fncRsv is a module that helps you use function whenever you want. It's simple, and undependent from other modules.

This module run async, which your server (or browser) can do other works while module standby. Notice that your server (or browser) can't afford this module if you register lots of functions at once.

Installing

Use npm:

$ npm install fncrsv

Use unpkg CDN:

<script src="https://unpkg.com/fncrsv@latest/lib/fncRsv.min.js"></script>

Usage

0.default

usage:

fncRsv(timeType, periodNum, timeValue, function);

Such parameter's data type exclude 'timeType' is different due to 'timeType'

1.periodic

usage:

fncRsv("periodic", periodNum, timeValue, function);

data type

periodNum: Number
timeValue: Number
reservFnc: Function

data role

periodNum: Number that you want to run function (0: unlimit)
timeValue: Interval that you want to run function
reservFnc: Function that you want to run periodic

example:

// example1: run function looping periodically at aspecific time interval

const testFunction = function () { 
    console.log(`Hello, fncRsv! Logged time is ${Date()}`);
}

const regMsg = fncRsv("periodic", 5, 1000, testFunction);
console.log(regMsg); // Function successfully registered. ~

// (1 seconds later)

// Hello, fncRsv! Logged time is ~ (repeat 5 times)

2.specific

usage:

fncRsv("specific", periodNum, timeValue, function);

data type

periodNum: Number
timeValue: Object
reservFnc: Function

structure of 'timeValue'

timeValue: {
    optionSetter: "HH",
    optionValue: 21
}

(ex: If you want to run function at 21:00
    -> timeValue: {
        optionSetter: "HH",
        optionValue: 21
    }
)

data role

periodNum: Number that you want to run function (0: unlimit)
timeValue: {
    optionSetter: option that you want to set basis ("HH" || "MM" || "SS")
    optionValue: value that set basis
}
reservFnc: Function that you want to run periodic

example:

// example2: run function looping periodically at aspecific time

const testFunction = function () { 
    console.log(`Hello, fncRsv! Logged time is ${Date()}`);
}



const regMsg = fncRsv("specific", 0, {
    optionSetter: "SS",
    optionValue: 40
}, testFunction);
console.log(regMsg); // Function successfully registered. ~

// (everytime when second correct '40')

// Hello, fncRsv! Logged time is ~ (repeat permanent)

3.onetime

usage:

fncRsv("onetime", periodNum, timeValue, function);

data type

periodNum: NULL (if input, it will be ignored)
timeValue: String (YYYYMMSSHHMMSS)
reservFnc: Function

data role

periodNum: null (no need in this option)
timeValue: Time that run function (YYYYMMDDHHMMSS)
reservFnc: Function that you want to run periodic

example:

// example3: run function at specific time just once

const testFunction = function () { 
    console.log(`Hello, fncRsv! Logged time is ${Date()}`);
}

const regMsg = fncRsv("onetime", null, "20200808201600", testFunction);
console.log(regMsg); // Function successfully registered. ~

// (when '2020-08-08 20:16:00')

// Hello, fncRsv! Logged time is Sat Aug 08 2020 20:16:00 GMT+0900 (GMT+09:00)

Reference

https://today-hello.tistory.com/13