Socket
Socket
Sign inDemoInstall

clock-angle

Package Overview
Dependencies
11
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    clock-angle

Find smallest angle between hour and minute hands on the face of a standard 12-hr clock, in degrees.


Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Install size
734 kB
Created
Weekly downloads
 

Readme

Source

clock-angle

Find smallest angle between hour and minute hands on the face of a standard 12-hr clock, in degrees.

Demo

https://lab.miguelmota.com/clock-angle

Install

npm install clock-angle

Usage

var clockAngle = require('clock-angle')

// 12 o'clock to hour hand
clockAngle(3) // 90
clockAngle(6) // 180

// 12 o'clock to minute hand
clockAngle(null, 15) // 90
clockAngle(null, 30) // 180

// hour hand to minute hand
clockAngle(3, 0) // 90
clockAngle(0, 15) // 82.5
clockAngle(12, 15) // 82.5
clockAngle(9, 15) // 172.5
clockAngle(11, 59) // 5.5

Test

npm test

License

MIT

Keywords

FAQs

Last updated on 24 Sep 2017

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc