function TestClassAttributeClassOnly::__invoke

Provides test content.

File

core/modules/system/tests/modules/router_test_directory/src/Controller/TestClassAttributeClassOnly.php, line 23

Class

TestClassAttributeClassOnly
Test controller: class-only #[Route] with bare __invoke().

Namespace

Drupal\router_test\Controller

Code

public function __invoke() : array {
  return [
    '#markup' => 'Testing class-only #[Route] with bare __invoke()',
  ];
}

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