New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@hey-mirror/clock

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hey-mirror/clock

## Example

  • 1.0.0-alpha.1
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

@hey-mirror/clock

Example

import { Clock } from '@hey-mirror/clock';

export const Display = () => {
  return (
    <Clock
      hour12
      locale='en-US'
    >
      <Clock.Hours />:<Clock.Minutes/>.<Clock.Seconds>{' '}
      <Clock.Period>
        <Clock.Period.AM>
          am
        </Clock.Period.AM>
        <Clock.Period.PM>
          pm
        </Clock.Period.PM>
      </Clock.Period>
    </Clock>
  );
};

API

Clock

PropDefaultType
children-ReactNode
hour12trueboolean
localeen-USstring

Hours

PropDefaultType
className-string
formatnumeric2-digit or numeric

Minutes

PropDefaultType
className-string
format2-digit2-digit or numeric

Seconds

PropDefaultType
className-string
format2-digit2-digit or numeric

Period

Only renders if hour12 is set on <Clock />.

PropDefaultType
children<><Period.AM /><Period.PM /></>ReactNode
className-string

You can use the default:

<Clock.Period />

or you can customize the displays:

<Clock.Period>
  <Clock.Period.AM>a.m.</Clock.Period.AM>
  <Clock.Period.PM>p.m.</Clock.Period.PM>
</Clock.Period>

If customizing, you must provide versions of both AM and PM.

Include both <Time.Period.AM /> and <Time.Period.PM /> — only the correct one will be rendered.

Period.AM / Period.PM

PropDefaultType
childrenAM or PMReactNode
className-string

FAQs

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