graphiti-api / graphiti

Stylish Graph APIs
https://www.graphiti.dev/
MIT License
974 stars 139 forks source link

Add support for conditional relationships #450

Open timkomip opened 1 year ago

timkomip commented 1 year ago

History

Setting the readable option on a relationship to a callables (procs, lambdas, etc) would only evaulate on load (once). Conditionally hiding relationships per request was not supported. Feature was disabled

Current State (before PR)

readable option on relationships (has_many, belongs_to) doesn't support callables (procs, lambdas, etc).

This PR

Adds support for setting readable with callables.

Changes