Schema relationships
Relationships between documents are called references. These references allow a schema to be used in another in various ways, so let's examine the various ways.
A one-to-one relationship
A reference connects one document to another. This is called a one-to-one relationship. An example of a one-to-one relationship might be a person and their street address.
The street address might only belong to one person. The address entity might have the following structure:
export default { Â Â name: 'address', Â Â type: 'document', Â Â title: 'Address', Â Â fields: [ { Â Â Â name: 'street', Â Â Â type: 'string', Â Â Â title: 'Street' }, { Â Â Â name: 'city', Â Â Â type: 'string', Â Â Â title: 'City' }, { Â Â Â name: 'postalCode', Â Â &...