Problem/Motivation
Once #3340712: Add Single Directory Components as a new experimental module has landed this issue will track the necessary work to get the module to beta and then a stable state.
Proposed resolution
Current status
- Currently (as of Drupal 10.0.x), Single Directory Components is proposed for core inclusion with experimental status and located in core/modules/sdc.
- Issues with SDC are still tracked and addressed in https://www.drupal.org/project/sdc first, then carried to the open MR.
- Drupal 10.1's first alpha release is scheduled for the week of Week of April 24, 2023. We are hoping to get #3340712: Add Single Directory Components as a new experimental module merged before that.
- Consensus to add SDC as an experimental module is gathered in #3313520: Single directory components in core.
Release Plan
In terms of the release schedule for Drupal 10, if this module is not included as an experimental module by May 2023 (when 10.1.0-beta1 will be released), then it will need to wait until 10.2. This will also delay the schedule for a future stable version. Normally for Experimental modules, the module gets to Beta, which triggers including it in a release as an Experimental module. Then at a later date, it becomes Stable and gets the Experimental status removed.
Roadmap for Beta (experimental status)
Here is a list of sub-issues that we currently have for that phase, all of which are must-haves to make "Beta" quality, so we can keep it as a live Experimental module in a full Drupal release:
- #3345924: Move schema validation library to require-dev
- #3345925: Fix issues reported by drupal-check
- This is a placeholder to link issues derived from a review on the MR in #3340712: Add Single Directory Components as a new experimental module.
Tasks originally proposed for this phase that made it into the patch before initial commit, or have since been finished:
- #3328636: Make schema props / slots optional
- #3328248: Allow classes and interfaces in the prop types metadata
- #3321150: [META] Increase automated test coverage
- #3320239: String props are improperly encoded/decoded
- #3319704: Allow overriding the library in the component definition
- #3319619: Restrict asset collection
- #3319616: Move components to "/components" from "/templates/components"
- #3317134: Always namespace components during usage and negotiation
- #3317173: Unable to use {% extends %} due to added code
- #3317158: Validate component props at rendering time
Roadmap for Stable
The schedule for stable release is not planned until SDC is in core as experimental.
To get this module to be ready for a stable release, here are some issues we'll need to resolve/finish, all of which are must-haves to make "Stable" quality:
- #3352256: [META] Move code from the experimental SDC module to core
- #3352257: [SDC] Validate and improve developer experience and helpfulness of error messages
- #3352258: [META] SDC: Improve and extend documentation
- #3352262: Create SDC "Quick start" documentation / code - We want this done by DrupalCon Pittsburgh!
- #3352272: SDC: Move the documentation from markdown to Drupal.org
- #3352260: If needed, create automated tests to validate SDC's use of Drupal escaping and Twig sandboxing
- #3352858: Move isRenderArray from SDC to Drupal\Core\Render\Element
- #3354389: [PP-1] Move single directory components API in \Drupal\Core\Render namespace
- #3356722: [PP-1] Remove schema references from contrib in SDC tests in core
- #3357382: Unable to override library auto-definition to add external CSS & JS
- #3357383: _locale_parse_js_file cannot open SDC JavaScript files
- #3365458: [Policy] SDC backwards compatibility policy
- #3385283: Components without props throw error
- #3375843: Allow other Twig node visitors to modify 'display_start' and 'display_end'
- #3365480: [SDC] Improve error handling during prop validation errors
- #3365455: Unhelpful error message with SDC when a optional variable is missing
Non-stable-blocking issues
- Umami uses more SDC components - #3364673: [META] Create Single Directory Components for the Umami theme
- #3352261: SDC: Prevent unwanted context passing with Twig include/embed functions
- #3362132: SDC: sdc_theme_test_enforce_schema test theme contains invalid schema definition
- #3365605: [Meta] Convert core UI components to use single directory components
- Allow schema references - #3352063: [PP-1] Allow schema references in Single Directory Component prop schemas
- #3365682: [SDC] Add a test for multiple *.component.yml in the same directory
- Olivero uses at least one SDC component - #3364672: [META] Create Single Directory Components for the Olivero theme






