Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Working with dates #30

Open
manuschillerdev opened this issue Feb 22, 2022 · 1 comment
Open

Working with dates #30

manuschillerdev opened this issue Feb 22, 2022 · 1 comment

Comments

@manuschillerdev
Copy link

Thanks for your great lib!
One common requirement is working with dates in JSON object (e.g. jwadhams/json-logic-js#6)

It would be awesome, if this could be baked into json-logic-rs.
Obviously, there is a lot to consider beforehand.

  • Which formats should be supported?
  • Which operations should be supported? (st, gt, eq)?
  • Can we support different time units when comparing to date strings? (e.g. two dates are more than 18 years apart from each other, two dates are more than 3 days apart from each other, two dates are less than 24 hours apart from each other).
  • Can we support dynamic values like "compare this date string to the current date: is it in the past? Is it in the future?"

Those are just some ideas off the top of my head, but I'd love to get a discussion going on how working with dates could look like in json-logic-rs :)

@jstewmon
Copy link
Contributor

👋 Hi @manuschillerdev, this library is not actively developed, but you may find the original author's fork json-logic-plus receptive to this feature request - its readme mentions supporting features like you described.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants