Introduce "adapters"
Goals
- Being able to write adaptors that can perform BE logic and adapt Drupal field values to match props
Non-goals
- Good UX
- Any UI to change the expression used for a
sourceType == dynamicprop value - Nested adapters
- Translations
- API representation (JSON:API) or otherwise
MR contents
- ** New Adapter plugin type and AdapterManager service **. Each plugin can:
-
addInput(string $input, mixed $itemBase)- adds input to adapter instance -
adapt()- adapts output -
outputSchemaMatch($schema)- checks if$schemamatches output schema of the adaptor
-
Tests (minimal)
-
✅ Kernel
Edited by Wim Leers