Remove Contentful Bundle
migo315 opened this issue · comments
Currently, you're taking the delivery client from the contentful-bundle for fetching elements. That's uncool.
best_it_contentful.delivery.client:
class: BestIt\ContentfulBundle\Service\Delivery\ClientDecorator
arguments:
- '@contentful.delivery'
- '@best_it_contentful.cache.pool.delivery'
- '@event_dispatcher'
- '@logger'
- '@best_it_contentful.delivery.response_parser.default'
calls:
- [setCacheTTL, ['%best_it_contentful.cache.content.cache_ttl%']]
- [setRoutableTypes, ['%best_it_contentful.routable_types%']]
- [setSlugField, ['%best_it_contentful.routing_field%']]
Instead let the user pass a delivery client as service id via the configuration. After that, you can remove the contentful-bundle as dependency and just use the contentful-sdk (which make your dependencies quite smaller) and the user can decide which delivery client should be used.
done