Problem/motivation

Drupal 10.3 made available defining [plugins using PHP Attributes](https://www.drupal.org/docs/drupal-apis/plugin-api/attribute-based-plugins), and these attributes on plugins are required in Drupal 12.

Currently, we define our plugins using docblock annotations. These can be converted using machine-translation tools, namely Drupal Rector.

Audit of Plugin instances

[0] => src/Plugin/Field/FieldFormatter/BootstrapHorizontalTabs.php
[1] => src/Plugin/Field/FieldType/BootstrapHorizontalTabs.php
[2] => src/Plugin/Field/FieldWidget/BootstrapHorizontalTabs.php

Acceptance criteria

- [ ] All plugins in the codebase that use annotations now use attribute syntax
- [ ] All annotation syntax has been removed (for future Drupal compatibility)
- [ ] All affected plugins are still registered and work as previous

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

mark_fullmer created an issue. See original summary.

mark_fullmer’s picture

Status: Active » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

  • mark_fullmer committed 1bad8c31 on 3.x
    #3559683 [Drupal 12] Convert plugin annotations to attributes
    

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.