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

react-period-of-stay-input

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-period-of-stay-input

React.js component for entering a period of stay in a hotel: check-in + check-out date

  • 4.1.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
15
increased by15.38%
Maintainers
1
Weekly downloads
 
Created
Source

Build Status

About

React.js component for entering a period of stay in a hotel: check-in day and check-out day. See the demo. In case when a native <input type="date"> implementation is not available, it's "polyfilled" with a jQuery UI datepicker (English only).

Installation

Made for Browserify.

npm install --save react-period-of-stay-input

Usage

See the code of the demo mentioned above. The polyfilling part is visible here.

Internationalization

react-intl-based. To translate the component, please pass the messages property, containing:

{
    'react-period-of-stay-input': {
        period: '{count, plural, =0 {Single day} =1 {1 night} other {# nights}}',
        checkInDay: 'Check-in day',
        checkOutDay: 'Check-out day'
    }
}

react-intl allows using react-period-of-stay-input uniformly in bigger applications, and passing all the namespaced translations, from the root, down the React components hierarchy, -- automatically, with the help of IntlMixin.

Please note, that react-intl depends on global Intl object. You can polyfill it with intl package:

if (!global.Intl) {
    require('intl');
}

Keywords

FAQs

Package last updated on 28 May 2015

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