public static function ResourceRoutes::getSubscribedEvents in JSON:API Resources 8
File
- src/
Unstable/ Routing/ ResourceRoutes.php, line 71
Class
- ResourceRoutes
- Route subscriber to decorate JSON:API Resource routes.
Namespace
Drupal\jsonapi_resources\Unstable\RoutingCode
public static function getSubscribedEvents() {
// Run before route_http_method_subscriber, so that we can ensure JSON:API
// Resource routes default to only GET methods if not set.
$events[RoutingEvents::ALTER][] = [
'decorateJsonapiResourceRoutes',
6000,
];
return $events;
}