function CommentItem::defaultFieldSettings

Overrides FieldItemBase::defaultFieldSettings

File

core/modules/comment/src/Plugin/Field/FieldType/CommentItem.php, line 43

Class

CommentItem
Plugin implementation of the 'comment' field type.

Namespace

Drupal\comment\Plugin\Field\FieldType

Code

public static function defaultFieldSettings() {
  return [
    'default_mode' => CommentManagerInterface::COMMENT_MODE_THREADED,
    'per_page' => 50,
    'form_location' => CommentItemInterface::FORM_BELOW,
    'anonymous' => CommentInterface::ANONYMOUS_MAYNOT_CONTACT,
    'preview' => DRUPAL_OPTIONAL,
  ] + parent::defaultFieldSettings();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.