As a poll owner, I want to be able to do a bulk import for date polls.
Describe possible solutions
See #2339
Additional context
Since implementing a locale-aware date string parser is incredibly hard, I'd recommend you not to try. You better force ISO 8601 dates. If you do so, date string parsing is as simple as calling moment(string, moment.ISO_8601) (don't use moment(string), as it's a wrapper around the discouraged Date.parse() function).
Describe the goal you'd like to achieve
As a poll owner, I want to be able to do a bulk import for date polls.
Describe possible solutions
See #2339
Additional context
Since implementing a locale-aware date string parser is incredibly hard, I'd recommend you not to try. You better force ISO 8601 dates. If you do so, date string parsing is as simple as calling
moment(string, moment.ISO_8601)
(don't usemoment(string)
, as it's a wrapper around the discouragedDate.parse()
function).