- 🇬🇧United Kingdom catch
I think this can be marked duplicate of 📌 Make Drupal core multi-frontend Active and 🌱 [Meta] Make Drupal the first "design-system native" CMS + Unify & simplify render & theme systems Active at this point.
Drupal’s current theming layer needs a rework to match the Render Engine rework – and with Web Components becoming more standard along with JavaScript support, another rework will be right behind it. With so much movement on the web front end, Drupal needs an architecture that supports this modern evolution of along with easing use of strategies such as decoupling.
I suggest we take a look at moving the theme layer into a microservice that takes REST requests and returns schemas and formatted HTML. The goal is effectively abstracting/decoupling layout and theme related elements from content and configuration.
The site building process generally is made up of one or more of the following roles (many times, a single individual taking up those roles, but they are still valuable distinctions):
The goal is to allow each of these teams to work as independently and efficiently as possible, and remove any tight coupling to any particular method or framework.
By decoupling the teams and technologies, we enable simpler reuse of the various layers and more flexible implementations in page composition and generation. That is to say, ideally the designer does not know or care what the rendering platform is, and ideally the developer doesn’t know or care what the framework, template engine or design is.
The proposal is to treat the reusable components as first class objects deliverable by an anonymous service (whether that be Drupal or some other platform is inconsequential). The components would be exposed with all information necessary to solicit the dynamic data necessary for rendering - The implementation would choose how to handle the collection and injection of dynamic data.
The current system could remain Twig (as it and Liquid become ever more popular) while allowing easier use of alternative systems. This also aids in decoupling as a developer can choose to request data directly from Drupal or structured HTML from the REST service gating the theming system. The added benefit here is that any application with access can use the same library of patterns and components from Drupal’s theming system.
Related Reading:
This issue composed by the Red Hat Web Patterns Working Group.
Closed: duplicate
Idea
Refactors an existing API or subsystem for consistency, performance, modularization, flexibility, third-party integration, etc. May imply an API change. Frequently used during the Code Slush phase of the release cycle.
Enhances an existing API or introduces a new subsystem. Depending on the size and impact, possibly backportable to earlier major versions.
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.
I think this can be marked duplicate of 📌 Make Drupal core multi-frontend Active and 🌱 [Meta] Make Drupal the first "design-system native" CMS + Unify & simplify render & theme systems Active at this point.