react-date-picker
Advanced tools
Comparing version 1.4.0 to 1.4.1
@@ -5,2 +5,4 @@ 'use strict' | ||
var nl = require('moment/locale/nl') | ||
var React = require('react') | ||
@@ -7,0 +9,0 @@ var DatePicker = require('./src/index') |
@@ -334,7 +334,2 @@ 'use strict' | ||
DatePicker.locale = function(locale){ | ||
console.log(locale,'!') | ||
require('moment/locale/' + locale) | ||
} | ||
module.exports = DatePicker |
{ | ||
"name": "react-date-picker", | ||
"version": "1.4.0", | ||
"version": "1.4.1", | ||
"description": "React Date Picker", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -40,2 +40,18 @@ react-date-picker | ||
## Custom locale | ||
If you want to use a custom locale, simply require the appropriate momentjs locale before `require`-ing `react-date-picker` | ||
Example: | ||
```jsx | ||
//make sure you require this first! | ||
var nl = require('moment/locale/nl') | ||
//and then require the date picker - it will use the locale you previously required | ||
var DatePicker = require('react-date-picker') | ||
... | ||
``` | ||
## Options | ||
@@ -42,0 +58,0 @@ |
@@ -334,7 +334,2 @@ 'use strict' | ||
DatePicker.locale = function(locale){ | ||
console.log(locale,'!') | ||
require('moment/locale/' + locale) | ||
} | ||
module.exports = DatePicker |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
133
0
1824581
26417