It contains the Document, Resource and Relationship classes that
perform most of the work interpreting a JSON:API structure.
Normally you would start by creating a Document from existing JSON:API data or using the fromURL
method to fetch data from a server. Then you can examine the resources in that document (resource
or resources) and traverse to other related resources (relatedResource or
relatedResources).
You have to provide an implementation of the Context interface to specify how documents should be fetched from
URLs. The documentation of the Context interface shows several possible implementations (e.g. using the Angular http client
or Axios).
This is the main module of Grivet.
It contains the Document, Resource and Relationship classes that perform most of the work interpreting a JSON:API structure.
Normally you would start by creating a Document from existing JSON:API data or using the fromURL method to fetch data from a server. Then you can examine the resources in that document (resource or resources) and traverse to other related resources (relatedResource or relatedResources).
You have to provide an implementation of the Context interface to specify how documents should be fetched from URLs. The documentation of the Context interface shows several possible implementations (e.g. using the Angular http client or Axios).
Based on version 1.0 of JSON:API.