t0gre/react-datepicker

IE11 not supported

Closed this issue · 3 comments

@datepicker-react/hooks or @datepicker-react/styled version
e.g. @datepicker-react/hooks@1.0.0

Describe the bug
Syntax errpr
Source code (including props configuration)
Steps to reproduce the behavior:




function h(e) {
  if (arguments.length < 1)
    throw new TypeError('1 argument required, but only ' + arguments.length + ' present')
  var t = Object.prototype.toString.call(e)
  return e instanceof Date || ('object' == typeof e && '[object Date]' === t)
    ? new Date(e.getTime())
    : 'number' == typeof e || '[object Number]' === t
    ? new Date(e)
    : (('string' != typeof e && '[object String]' !== t) ||
        'undefined' == typeof console ||
        (console.warn(
          "Starting with v2.0.0-beta.1 date-fns doesn't accept strings as arguments. Please use `parseISO` to parse strings. See: https://git.io/fjule",
        ),
        console.warn(new Error().stack)),
      new Date(NaN))
}

If you have custom methods that you are passing into a @datepicker-react component / hooks, please include the source for those as well.

Screenshots/Gifs
If applicable, add screenshots or gifs to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22]

Smartphone (please complete the following information):

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Is the issue reproducible in Storybook?
Please link to the relevant storybook example

Additional context
Add any other context about the problem here.

I pulled down thee source and compiled locally, then I noticed with a local complication and replacing the module with my local copy it worked. I think there was an issue with trailing commas in the date-fns module. I am not sure exactly, but you might want to try a release to see if that resolves the problem if a dependency is blocking this well-crafted component from workin in IE.

I will examine.

Check version v2.2