benjaminkott / bootstrap_package

Bootstrap Package delivers a full configured theme for TYPO3, based on the Bootstrap CSS Framework.

Home Page:https://www.bootstrap-package.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Best way to re-use content elements in a custom frontend plugin

lksnmnn opened this issue · comments

Support

Description

I am currently implementing a custom frontend plugin which should render a detail view of a custom content type. The idea is to allow the editor to put in the data in more structured way instead of having to build a page "by convention" for this type of data.

However, I was wondering if there is a clean way to re-use the content elements from bootstrap package for rendering, so I don't have to rebuild the templates / partials from scratch (making the app harder to maintain in the future).

So far I had the following ideas:

  1. Just connect my custom data model to tt_content and allow the editor to configure the data there (i.e. stage, gallery, quote,...). Would work, but goes against the idea of having the data neatly in their own tables. (I.e. this is basically the way theNews extension works)

  2. Have a custom template that renders the bootstrap package content element templates. Hardcode data like frame_type etc. to get the same look. A) I am not sure if this is possible in Typo3, since CEs are templates not partials? B) It would required quite a bit of work pass the required data structure to the templates.

  3. Just build custom templates / partials. These could either re-use some of the classes from bootstrap package to get the existing styling for free or simple re-build from scratch. This would effectly negate some of the benefits we have from using bootstrap-package and would need to be maintainend separately.

Any clues or links to existing documention would be very much appreciated :)

Cheers,
Lukas