Integrate w/Content Delivery API & maintain backwards compatibility #97
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The UmbNav library is not currently compatible with the Umbraco Content Delivery API. To use the library with the content delivery API currently requires creating custom overrides within a given application. This PR implements the necessary code to allow for the UmbNav library to return useful content via the Umbraco Content Delivery API in versions of Umbraco that have Umbraco Content Delivery API available (v12 and up).
Without either custom overrides or this update to the library itself, when returning UmbNavItems via the Content Delivery API I received an alternating experience between a 500 error and content stuck in a recursive loop (the json ignore attribute on content in class UmbNavItem is not recognized by the content delivery api because the existing class, UmbNavValueConverter only extends PropertyValueConverterBase but does not also implement IDeliveryApiPropertyValueConverter).
See this issue for greater detail: #96