Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@visimedia/part-of-day

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@visimedia/part-of-day

A simple TS compatible library that returns either morning, afternoon or evening dependent on a given EPOCH time.

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
2
Created
Source

Contributors Forks Stargazers Issues MIT License LinkedIn


Logo

Part of Day

A simple TS compatible library that returns either morning, afternoon or evening dependent on a given EPOCH time.
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License
  7. Contact
  8. Acknowledgments

About The Project

Built With

  • Node
  • TypeScript

(back to top)

Getting Started

Part of Day is a dependency free typescript compatible module

Prerequisites

This is an example of how to list things you need to use the software and how to install them.

  • npm
    npm install npm@latest -g
    

Installation

  1. Install NPM package
    npm install @visimedia/part-of-day
    

(back to top)

Usage

Part of Day comes with 3 functions. get, getByHour and getNow. All functions return either MORNING, AFTERNOON or EVENING dependent on the time of day.

get consumes epoch time (in milliseconds)

get(epochTime)

getByHour consumes the hour of the day

getByHour(14)

getNow consumes no parameters and returns the current time of day

getNow()

(back to top)

Roadmap

  • More detailed configuration
  • Capitalisation control

See the open issues for a full list of proposed features (and known issues).

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Contact

VisiMedia - @VisiMedia - contact@visimedia.co.uk
Ben Lewis - @BenjiSoft - ben.lewis@visimedia.co.uk

Project Link: https://github.com/VisiSolutions/Part-of-Day

(back to top)

Keywords

FAQs

Package last updated on 11 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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc