public function registerUrlRules(RegisterUrlRulesEvent $event)
    {
        foreach ($this->getSettings()->endpoints as $pattern => $config) {
            $event->rules[$pattern] = [
                'route' => 'element-api',
                'defaults' => ['pattern' => $pattern],
            ];
        }
    }
public function registerUrlRules(RegisterUrlRulesEvent $event)
    {
        foreach ($this->getSettings()->endpoints as $pattern => $config) {
            $event->rules[$pattern] = [
                'route' => 'element-api',
                'defaults' => ['pattern' => $pattern],
            ];
        }
    }
public function registerUrlRules ( RegisterUrlRulesEvent $ event ) { foreach ( $ this -> getSettings ( ) -> endpoints as $ pattern => $ config ) { $ event -> rules [ $ pattern ] = [ 'route' => 'element-api' , 'defaults' => [ 'pattern' => $ pattern ] , ] ; } }
Registers the site URL rules.

@param RegisterUrlRulesEvent $event
Registers the site URL rules .