Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 293279

Convert hook_element_info() to annotated classes

$
0
0

Problem/Motivation

#1617948: [policy for now] New standard for documenting form/render elements and properties explains the problem space.

Proposed resolution

This will introduce a new ElementInfo annotation, and use that to replace hook_element_info().

We will NOT provide a plugin-level alter, since ElementInfo will only contain the plugin ID in the annotation.
The actual element info will be in a method on the class.

The existing alter hook will remain, running on the collected info.

Remaining tasks

Decide on more advanced ways to document the properties used by the elements (or punt that to another issue?)

User interface changes

N/A

API changes

No API change yet, but Drupal\*\ElementInfo\* will act as a replacement for hook_element_info().


Viewing all articles
Browse latest Browse all 293279

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>