Natural language processing for date chooser

This library might help with implementation: GitHub - wanasit/chrono: A natural language date parser in Javascript · GitHub

That said I suspect it would be a challenge to get robust language support for this.

The current fully supported languages are en , ja , and fr ( de and pt are partially supported). Other languages from v1 ( nl and zh ) are under development.


Also, another UX pattern to consider is automatically replacing date strings in the body of a post with Discourse date/time objects. Sort of like one-boxing but for dates. E.g. if I type “next monday at 2pm” in my post, it automatically converts that to 2021-08-17T18:00:00Z.

5 Likes