Syncing a content type with its schema

If you make a change to a content type schema and that schema has already been used to register a content type, you need to ensure that the content type is "synced" with the schema so that it is using the latest version.

If you make changes to a content type schema you should consider how the changes affect the way existing content is viewed and edited. This page provides some guidelines.

Choosing a content type to sync with its schema

To sync a content type with its schema, view the content types window by choosing "Content types" from the Development tab and select "Sync with schema" from the contextual menu of the content type that you want to update.

Syncing a content type with its schema
Syncing a content type with its schema

A warning dialog will be displayed to inform you that any changes you make will apply to existing content when viewed in the content editing window in production. See the Guidelines for making a change to a content type schema section on this page for more details of how any changes you make may affect existing content.

A warning dialog is displayed. Press OK to sync the content type with the updated schema
A warning dialog is displayed. Press OK to sync the content type with the updated schema

Click the "Ok" button to go ahead and sync the content type with the updated schema. If the updated content type is valid JSON schema, a success message will be displayed.

If the updated content type is not valid JSON schema, then an error will be displayed. In this case you'll need to identify the problem with the JSON schema, upload the content type to the hosting service and sync it again. If the schema has been created using the schema editor and stored internally, then you can open it from the content type schema window.

An error message is displayed if the content type cannot be synced with its schema
An error message is displayed if the content type cannot be synced with its schema

Guidelines for making changes to a content type

If you update a content type schema that has been used in a registered content type from which content has been created, changing the name, type or validation defined for a property will require users to enter new values for the updated properties when editing existing content.

Content published using the previous version of the content type schema can still be consumed, but if the content is edited and then re-published, you may need to update your front end rendering code.

The following sections explain the various changes you can make to content type schemas and the impact each type of change has on existing content.

Changing a property name

  • Dynamic Content will treat the renamed property as a new property and data entered for the property under its previous name will be lost.
  • When editing existing content, the renamed property will be initially empty. The user will need to enter new data for property and save the content.
  • For content published using the previous version of the content type, the property will be available under its old name until the user re-saves and publishes the content.
  • You will need to modify your front end rendering code to consume content with the renamed property.

Changing a property title and description

  • The content label and explanatory text are shown in the content editing window and will not effect the structure of the content.

Adding a new property

  • Existing content will not be effected
  • You may choose to change the property order when updating the content type.
  • You may also need to update your front end rendering code to include the new property.

Removing a property

  • When viewing existing content, the property will no longer be visible in the content editing window.
  • Existing published content will continue to serve the old property until it is saved and re-published.

Changing a property type

  • Dynamic Content will treat this as a new property and any data entered for the property under its old name will be lost.
  • When editing existing content, the renamed property will be initially empty. The user will need to enter new data for property and save the content.
  • Changing the property type also includes changing it into a localizable content type.

Changing Validation on a property

  • No changes the way existing content is viewed
  • If a previously entered value for this property is no longer valid, then it must be updated to be valid before the content can be saved.

The schema editor

Content type format

Property types

Validation

results matching ""

    No results matching ""