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

[IDEA] Callable data #132

Open
gpibarra opened this issue Sep 27, 2023 · 0 comments
Open

[IDEA] Callable data #132

gpibarra opened this issue Sep 27, 2023 · 0 comments

Comments

@gpibarra
Copy link

Instead of passing all the data as parameters, sometimes it is necessary to calculate it on the fly, e.g.

jsonLogic.apply({ "var": ["my_input"] }, function (name, default value) {
      return $('input[name="'+name+'"]')?.val();
});

See master...gpibarra:json-logic-js:callable_data

Also, in php it may make sense to query the database and only bring back the necessary data and not the entire data set.

See jwadhams/json-logic-php@master...gpibarra:json-logic-php:callable_data

how about?

I could make a PR of those repos (Javascript and PHP) but we had to see if it can be replicated in other languages (Python, Java, etc.)

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

1 participant