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

Handle recursion #6

Open
2 tasks done
shgysk8zer0 opened this issue Aug 16, 2017 · 1 comment
Open
2 tasks done

Handle recursion #6

shgysk8zer0 opened this issue Aug 16, 2017 · 1 comment

Comments

@shgysk8zer0
Copy link
Owner

Please check ([x]) all of the following

All other issues will be closed as invalid

  • My issue is with the specification, not with the vocabulary or schemas
  • My issue is not with any particular language or implementation

Describe your issue

How can recursion be prevented? What can be done when data for a Person is requested, and that Person has a worksFor property, which lists the Person as an employee?

Do you have sample markup & data?

{
    "@type": "Person",
    "@context": "http://schema.org",
    "name": "John Smith",
    "worksFor": {
        "@type": "Organization",
        "employee": [{
            "@type": "Person",
            "name" "John Smith"
        }, {}]
    }
}
<div itemtype="" itemscope="">

</div>

If you have any suggestions, please share:

This may be solved by only returning a URL for complex properties. If not, perhaps JSON-LD
identifies a means of referencing other objects without replicating them. I don't think this will be a
problem on servers in most programming languages, but it will be a problem when converted into
JSON.

@shgysk8zer0
Copy link
Owner Author

Using a URL will work, but is useless in cases where Organization data is requested for the response.

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

No branches or pull requests

1 participant